Focal Point Banner


As of December 1, 2020, Focal Point is retired and repurposed as a reference repository. We value the wealth of knowledge that's been shared here over the years. You'll continue to have access to this treasure trove of knowledge, for search purposes only.

Join the TIBCO Community
TIBCO Community is a collaborative space for users to share knowledge and support one another in making the best use of TIBCO products and services. There are several TIBCO WebFOCUS resources in the community.

  • From the Home page, select Predict: WebFOCUS to view articles, questions, and trending articles.
  • Select Products from the top navigation bar, scroll, and then select the TIBCO WebFOCUS product page to view product overview, articles, and discussions.
  • Request access to the private WebFOCUS User Group (login required) to network with fellow members.

Former myibi community members should have received an email on 8/3/22 to activate their user accounts to join the community. Check your Spam folder for the email. Please get in touch with us at community@tibco.com for further assistance. Reference the community FAQ to learn more about the community.


Focal Point    Focal Point Forums  Hop To Forum Categories  WebFOCUS/FOCUS Forum on Focal Point     [SOLVED] (FOC015) THE TEST VALUE IS LONGER THAN THE FIELD FORMAT LENGTH

Read-Only Read-Only Topic
Go
Search
Notify
Tools
[SOLVED] (FOC015) THE TEST VALUE IS LONGER THAN THE FIELD FORMAT LENGTH
 Login/Join
 
Gold member
posted
hi,

i have below code and its throwing below error , im guessing its IF else statemnet issue but could not resolve it . if someone can help me with it/

(FOC015) THE TEST VALUE IS LONGER THAN THE FIELD FORMAT LENGTH: HOME ROAMER MSG

CODe is as below

  
 -IF 0      NE 0 GOTO ERR;
 -*
 DEFINE FILE UPCS15
 BILL_C/A7='/   ';
 CYCOD_C/A2=' ';
 AIR_DUR_LLK/P16.4=AIR_DUR_IN_MIN;
 TOLL_DUR_LLK/P16.4=TOLL_DUR_IN_MIN;
 -*  chnage
 SORT1/A7 = IF MESSAGE_TYPE EQ 'HOME MSG'        THEN 'HOME'
       ELSE IF MESSAGE_TYPE EQ 'ROAMING MSG'     THEN 'ROAMING'
       ELSE IF MESSAGE_TYPE EQ 'HOME ROAMER MSG' OR 'EXT. HOME MSG' THEN 'HRM'
       ELSE IF MESSAGE_TYPE EQ 'GPRS ROAM MSG'   THEN 'GPRS' ;
 -*
 SORT2/A9=SORT1||CANCEL_IND||BALANCE_DATE;
 SORTP/A15=SORT2||AIR_FREE_CODE_IND||CALL_FRWD_IND;
 -*
 END
 -RUN



and mas file has structure as below

FILE=upcs15 ,SUFFIX=FIX
SEGNAME=FIRST
FIELDNAME=FTR_SERVICE_TYPE ,ALIAS= ,FORMAT=A1 ,ACTUAL=A1 ,$
FIELDNAME=SUB_MARKET_CODE ,ALIAS= ,FORMAT=A3 ,ACTUAL=A3 ,$
FIELDNAME=CANCEL_IND ,ALIAS= ,FORMAT=A1 ,ACTUAL=A1 ,$
FIELDNAME=CANCELING_ENTITY ,ALIAS= ,FORMAT=A1 ,ACTUAL=A1 ,$
FIELDNAME=MESSAGE_TYPE ,ALIAS= ,FORMAT=A13 ,ACTUAL=A13 ,$
FIELDNAME=BALANCE_DATE ,ALIAS= ,FORMAT=A1 ,ACTUAL=A1 ,$
FIELDNAME=AIR_FREE_CODE_IND,ALIAS= ,FORMAT=A1 ,ACTUAL=A1 ,$
FIELDNAME=CALL_FRWD_IND ,ALIAS= ,FORMAT=A1 ,ACTUAL=A1 ,$
FIELDNAME=NUM_OF_USG ,ALIAS= ,FORMAT=I9 ,ACTUAL=I4 ,$
FIELDNAME=AIR_CHARGES ,ALIAS= ,FORMAT=P13.2 ,ACTUAL=P6 ,$
FIELDNAME=AIR_DUR_IN_MIN ,ALIAS= ,FORMAT=P19.4 ,ACTUAL=P9 ,$
FIELDNAME=TOLL_CHARGES ,ALIAS= ,FORMAT=P13.2 ,ACTUAL=P6 ,$
FIELDNAME=TOLL_DUR_IN_MIN ,ALIAS= ,FORMAT=P19.4 ,ACTUAL=P9 ,$
FIELDNAME=AC_CHARGES ,ALIAS= ,FORMAT=P13.2 ,ACTUAL=P6 ,$
FIELDNAME=TAXES ,ALIAS= ,FORMAT=P13.2 ,ACTUAL=P6 ,$



Thanks in advance for ur help

This message has been edited. Last edited by: FP Mod Chuck,


WebFOCUS, Linux
Excel, CSV
 
Posts: 62 | Registered: May 23, 2017Report This Post
Expert
posted Hide Post
quote:
IF MESSAGE_TYPE EQ 'HOME ROAMER MSG'

FIELDNAME=MESSAGE_TYPE ,ALIAS= ,FORMAT=A13 ,ACTUAL=A13 ,$


You really cannot work this one out?

Perhaps it's time to take a maths class?

T



In FOCUS
since 1986
WebFOCUS Server 8.2.01M, thru 8.2.07 on Windows Svr 2008 R2  
WebFOCUS App Studio 8.2.06 standalone on Windows 10 
 
Posts: 5694 | Location: United Kingdom | Registered: April 08, 2004Report This Post
Platinum Member
posted Hide Post
quote:
Perhaps it's time to take a maths class?

... or be change you screen name? Smiler

Kofi


Client Server 8.1.05: Apache; Tomcat;Windows Server 2012
Reporting Server 8.1.05; Oracle; MS SQL; Windows Server 2012
 
Posts: 106 | Registered: April 06, 2009Report This Post
Gold member
posted Hide Post
hi,

I already tried code with changing size to A15/A13 still showing same error.


WebFOCUS, Linux
Excel, CSV
 
Posts: 62 | Registered: May 23, 2017Report This Post
Expert
posted Hide Post
quote:
HOME ROAMER MSG

The string is longer than the ACTUAL length, as defined in the metadata for table or file you're reading.

If you view the data in the table or file, do you see that value?

How was the metadata for this table or file created?


Francis


Give me code, or give me retirement. In FOCUS since 1991

Production: WF 7.7.05M, Dev Studio, BID, MRE, WebSphere, DB2 / Test: WF 8.1.05M, App Studio, BI Portal, Report Caster, jQuery, HighCharts, Apache Tomcat, MS SQL Server
 
Posts: 10577 | Location: Toronto, Ontario, Canada | Registered: April 27, 2005Report This Post
Virtuoso
posted Hide Post
quote:
Originally posted by Genius:
...
SORT1/A7 = IF MESSAGE_TYPE EQ 'HOME MSG' THEN 'HOME'
ELSE IF MESSAGE_TYPE EQ 'ROAMING MSG' THEN 'ROAMING'
ELSE IF MESSAGE_TYPE EQ 'HOME ROAMER MSG' OR 'EXT. HOME MSG' THEN 'HRM'
ELSE IF MESSAGE_TYPE EQ 'GPRS ROAM MSG' THEN 'GPRS' ;
...


Just to note in passing -- In a cascade of "if then else" clauses in a Define, always provide a final "ELSE '...'", to control what happens when none of the conditions is fired.

As it stands, if MESSAGE_TYPE is none of the above in a particular incoming record, then the value for SORT1 is unspecified (and will probably be the holdover value from the previous record). And it looks like incoming values of 'HOME ROAMER M', which is none of the above, can be anticipated.
 
Posts: 1925 | Location: NYC | In FOCUS since 1983 | Registered: January 11, 2005Report This Post
Expert
posted Hide Post
If this came across a bit harsh then I apologise .... However,

You really need to do your searches before you post questions like this because most of what you have asked has arisen and been answered before. A little research on your part would likely have given you indications of what the issue was. You then have to really examine what the message is telling you and you should be able to work out the resolution.


T



In FOCUS
since 1986
WebFOCUS Server 8.2.01M, thru 8.2.07 on Windows Svr 2008 R2  
WebFOCUS App Studio 8.2.06 standalone on Windows 10 
 
Posts: 5694 | Location: United Kingdom | Registered: April 08, 2004Report This Post
Expert
posted Hide Post
How many people does it take to help a genius? Big Grin


Francis


Give me code, or give me retirement. In FOCUS since 1991

Production: WF 7.7.05M, Dev Studio, BID, MRE, WebSphere, DB2 / Test: WF 8.1.05M, App Studio, BI Portal, Report Caster, jQuery, HighCharts, Apache Tomcat, MS SQL Server
 
Posts: 10577 | Location: Toronto, Ontario, Canada | Registered: April 27, 2005Report This Post
  Powered by Social Strata  

Read-Only Read-Only Topic

Focal Point    Focal Point Forums  Hop To Forum Categories  WebFOCUS/FOCUS Forum on Focal Point     [SOLVED] (FOC015) THE TEST VALUE IS LONGER THAN THE FIELD FORMAT LENGTH

Copyright © 1996-2020 Information Builders