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     [CLOSED] FOC1346) : FORMAT ERROR: Record 35 , Column 28

Read-Only Read-Only Topic
Go
Search
Notify
Tools
[CLOSED] FOC1346) : FORMAT ERROR: Record 35 , Column 28
 Login/Join
 
Gold member
posted
Hi,

Im getting below error in my focus

FOC1346) : FORMAT ERROR: Record 35 , Column 28
(FOC1346) : FORMAT ERROR: Record 35 , Column 36
(FOC1346) : FORMAT ERROR: Record 35 , Column 44
(FOC1346) : FORMAT ERROR: Record 35 , Column 52
(FOC1346) : FORMAT ERROR: Record 35 , Column 60
(FOC1346) : FORMAT ERROR: Record 35 , Column 68
(FOC1130) FORMAT CONVERSION ERROR FIELD/KEY : AIR_CH
(FOC1130) FORMAT CONVERSION ERROR FIELD/KEY : AIR_MIN
(FOC1130) FORMAT CONVERSION ERROR FIELD/KEY : TOLL_CH
(FOC1130) FORMAT CONVERSION ERROR FIELD/KEY : TOLL_DUR_IN_MINS
(FOC1130) FORMAT CONVERSION ERROR FIELD/KEY : AC_CH
(FOC1130) FORMAT CONVERSION ERROR FIELD/KEY : TOTAL_CH


In code i defined them as below NUM_OF_USAGE1/I9=NUM_OF_USAGE;
AIR_CH1/P12.2=AIR_CH;
AIR_MIN1/P12=AIR_MIN;
TOLL_CH1/P12.2=TOLL_CH;
TOLL_DUR_IN_MINS1/P12=TOLL_DUR_IN_MINS;
AC_CH1/P12.2=AC_CH;
TOTAL_CH1/P12.2=TOTAL_CH;
and in mass file is as below

FIELDNAME=AIR_CH ,ALIAS= ,FORMAT=P11.2 ,ACTUAL=P5 ,$
FIELDNAME=AIR_MIN ,ALIAS= ,FORMAT=P16.2 ,ACTUAL=P8 ,$
FIELDNAME=TOLL_CH ,ALIAS= ,FORMAT=P11.2 ,ACTUAL=P5 ,$
FIELDNAME=TOLL_DUR_IN_MINS ,ALIAS= ,FORMAT=P16.2 ,ACTUAL=P8 ,$
FIELDNAME=AC_CH ,ALIAS= ,FORMAT=P11.2 ,ACTUAL=P5 ,$
FIELDNAME=TAXES_AMT ,ALIAS= ,FORMAT=P11.2 ,ACTUAL=P5 ,$
FIELDNAME=TOTAL_CH ,ALIAS= ,FORMAT=P13.2 ,ACTUAL=P6 ,$

I also tried converting it to decimal but didnt work if someone can help me??

thanks in advance

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


WebFOCUS, Linux
Excel, CSV
 
Posts: 62 | Registered: May 23, 2017Report This Post
Virtuoso
posted Hide Post
What kind of data is this? The error is complaining about the record 35. If this is a CSV or Excel file, check and make sure that row has a valid number in it.


WebFOCUS 8206, Unix, Windows
 
Posts: 1853 | Location: New York City | Registered: December 30, 2015Report This Post
Virtuoso
posted Hide Post
Genius

Since it doesn't happen on every recoord I suspect that the actual data in the database is corrupt and not in packed format.


Thank you for using Focal Point!

Chuck Wolff - Focal Point Moderator
WebFOCUS 7x and 8x, Windows, Linux All output Formats
 
Posts: 2127 | Location: Customer Support | Registered: April 12, 2005Report This Post
Gold member
posted Hide Post
Hi ,

thanks for the help

it is call duration and minutes . and record we are passing is having correct values.
Can it be issue that we need to convert packed data into some other format


WebFOCUS, Linux
Excel, CSV
 
Posts: 62 | Registered: May 23, 2017Report This Post
Virtuoso
posted Hide Post
What's the database format?
How did you create the synonym for this database?
Have you made changes to the synonym?
If you PRINT the original fieldsnames will you get the same error?

These are diagnostics you will have to do before you ask us to help you figure out what went wrong. Providing partial information will only give you partial answers.

Try the code you are using with a

WHERE READLIMIT EQ 1;
WHERE RECORDLIMIT EQ 1;

Do you still get an error?


WebFOCUS 8206, Unix, Windows
 
Posts: 1853 | Location: New York City | Registered: December 30, 2015Report This Post
Virtuoso
posted Hide Post
Also, try first to perform a sample data from the master file itself and can do a "Check" : right click on master file then select "Check" to be sure that the master is valid.

I also notice that for all fields except AIR_MIN and TOTAL_CH you have expended the format where for those two you have decreased, is that what you want ? May result in overflow...


WF versions : Prod 8.2.04M gen 33, Dev 8.2.04M gen 33, OS : Windows, DB : MSSQL, Outputs : HTML, Excel, PDF
In Focus since 2007
 
Posts: 2409 | Location: Montreal Area, Qc, CA | Registered: September 25, 2013Report This Post
Gold member
posted Hide Post
Hi,

Yes i already tried with original field names but still shows same error,

and input we are passing seems to be correct. in[put im passing is as below

REC<1> BAN<101855488> <0>
ban_name =
air_charges = <0.000000>
air_dur_in_mins = <0.000000>
toll_charges = <0.000000>
toll_dur_in_mins = <0.000000>
ac_charges = <0.000000>
taxes_amt = <0.000000>
total_charges = <0.000000>
REC<2> BAN<101855488> <140>
ban_name =
air_charges = <0.000000>
air_dur_in_mins = <239.000000>
toll_charges = <0.000000>
toll_dur_in_mins = <0.000000>
ac_charges = <0.000000>
taxes_amt = <0.000000>
total_charges = <0.000000>
REC<3> BAN<101855488> <0>
ban_name =
air_charges = <0.000000>
air_dur_in_mins = <0.000000>
toll_charges = <0.000000>
toll_dur_in_mins = <0.000000>
ac_charges = <0.000000>
taxes_amt = <0.000000>
total_charges = <0.000000>

i have below my whole fex file so u guys will get an idea if im doing wrong somewhere
 

-SET &ECHO=ALL;
-*
-*
-SET &&MARKET=FGETENV(10,'TLG_MARKET',3,'A3');
-*
-*
-*---------------* Define the input and output file names *-----------------*
-*
-* Linux Migration Start Change
-SET &WORKDIR=FGETENV(128,'TLG_SHORTNAME_DIR',128,'A128');
-SET &UNAME_RESULT = FGETENV(12,'UNAME_RESULT',20,'A20');
-* Linux Migration End Change

-SET DATA_NAME = FGETENV(14,'EXT_SHORT_NAME',20,'A20');
-* Linux Migration Start Change
-SET DATA_FILE = (&WORKDIR || '/'||&DATA_NAME);
-IF  &UNAME_RESULT EQ 'Linux' THEN GOTO L1556551 ;
-SET DATA_FILE = ('../'||&DATA_NAME);
-L1556551

-* Linux Migration End Change
-TYPE file data name is   &DATA_NAME
-SET REP_NAME  = FGETENV(14,'LAY_SHORT_NAME',20,'A20');
-TYPE  file report name is &REP_NAME
-* Linux Migration Start Change
-SET &&REP_FILE  = (&WORKDIR || '/'||&REP_NAME);
-IF  &UNAME_RESULT EQ 'Linux' THEN GOTO L1556631 ;
-SET &&REP_FILE  = ('../'||&REP_NAME);
-L1556631

-* Linux Migration End Change
-*
-*----* Getting report's parameters *--------------------------------*
-SET &&CYCLE= FGETENV(9,'BL_CYC_CD',4,'A4');
-SET &&MONTH= FGETENV(10,'BL_CYC_MON',2,'A2');
-SET &&YEAR= FGETENV(11,'BL_CYC_YEAR',4,'A4');
-SET &MARKET = FGETENV(12,'TLG_MARKETID',3,'A3');
-*----* Set report parameters *------------------------------------*
-SET &I=1;
-SET &&APPARTXT.&I = 'CYCLE: ';
-SET &&APPARVAL.&I = &&CYCLE;

-SET &I=2;
-SET &&APPARTXT.&I = 'MONTH: ';
-SET &&APPARVAL.&I = &&MONTH;
-SET &I=3;
-SET &&APPARTXT.&I = 'YEAR: ';
-SET &&APPARVAL.&I = &&YEAR;
-*
-*------------------* Define the Report Header *----------------------------*
-SET &REPCODE='BLHO-01-HND';
-SET &REPNAME='Billing Handoff Report';

-*-----------* Define the Indicator for data size (kb/mb/gb/tb) *------- ---*
-*INCLUDE defuom.fex
-*----------------------------------------------------------------------

FILEDEF OFFLINE DISK &&REP_FILE
OFFLINE
-*SET PANEL 250
-INCLUDE gnrpdef.fex
-*
-*------------------------* Define input file *-----------------------------*
-*
FILEDEF BLHOFF DISK &DATA_FILE (RECFM F  LRECL 84

-*
-*------------------* Initialization of parameters *------------------------*
DEFINE FILE BLHOFF
RAM/A1=DECODE CALL_TYPE( H '1' R '2' E '3' Z '4' G '5' B '6' F '7' );
TYPE/A15=DECODE CALL_TYPE( H 'HOME MSG '
                           R 'ROAMING MSG '
                           E 'EXT. HOME MSG '
                           Z 'ZONED MSG '
                           G 'HOME  MSG '
                           B 'ROAMING  MSG '
                           F 'EXT. HOME  MSG ' );

BALANCE/A35=DECODE NOT_BAL_IND (N 'No Balance  Handling             '
                                Y 'Not Processed by Bill Preparation');
INDX/A2=IF (CALL_TYPE EQ 'H') OR (CALL_TYPE EQ 'R') OR
(CALL_TYPE EQ 'E') OR (CALL_TYPE EQ 'Z') THEN 'AV' ELSE 'BD' ;
IND1/A1='Z';
BAN1/I9=999999999;
CM/A1=',';
NUM_OF_USAGE1/I9=NUM_OF_USAGE;
AIR_CH1/P12.2=AIR_CH;
AIR_MIN1/P12=AIR_MIN;
TOLL_CH1/P12.2=TOLL_CH;
TOLL_DUR_IN_MINS1/P12=TOLL_DUR_IN_MINS;
AC_CH1/P12.2=AC_CH;
TOTAL_CH1/P12.2=TOTAL_CH;
END
TABLE FILE BLHOFF
SUM
      NUM_OF_USAGE
      AIR_CH
      AIR_MIN
      TOLL_CH
      TOLL_DUR_IN_MINS
      AC_CH
-*      TAXES_AMT
      TOTAL_CH
BAN_NAME
BY NOT_BAL_IND
BY BAN
-*BY INDX
BY TYPE
-*BY RAM
ON TABLE HOLD AS EXT
END
-RUN
FILEDEF EXT DISK ext.ftm (APPEND
-RUN
TABLE FILE BLHOFF
SUM
      NUM_OF_USAGE
      AIR_CH
      AIR_MIN
      TOLL_CH
      TOLL_DUR_IN_MINS
      AC_CH
-*      TAXES_AMT
      TOTAL_CH
BAN_NAME
BY NOT_BAL_IND
BY BAN1
-*BY INDX
BY TYPE
-*BY RAM
ON TABLE SAVE AS EXT
END
-RUN
TABLE FILE BLHOFF
SUM
      NUM_OF_USAGE
      AIR_CH
      AIR_MIN
      TOLL_CH
      TOLL_DUR_IN_MINS
      AC_CH
-*      TAXES_AMT
      TOTAL_CH
BAN_NAME
BY IND1
BY BAN1
-*BY INDX
BY TYPE
-*BY RAM
ON TABLE SAVE AS EXT
END
-RUN

DEFINE FILE EXT
-*INDN/A10=IF INDX EQ 'AV' THEN 'Voice' ELSE 'GPRS';
BALANCE/A35=DECODE NOT_BAL_IND (N 'No Balance  Handling             '
                                Y 'Not Processed by Bill Preparation');
-*LCCOUNT/I6 = IF NOT_BAL_IND EQ 'N' OR 'Y' THEN LAST CCOUNT;
-*SET &I=0;
CCOUNT/I6  =IF NOT_BAL_IND NE LAST NOT_BAL_IND THEN 1  ELSE
IF BAN EQ 999999999 THEN CCOUNT ELSE IF BAN NE LAST BAN THEN CCOUNT + 1;
TCOUNT/I6  =IF BAN EQ 999999999 THEN TCOUNT ELSE
IF BAN NE LAST BAN THEN TCOUNT + 1 ELSE TCOUNT;
ABAN/A19=IF BAN EQ 999999999 THEN 'TOTAL ' ELSE  'TOTAL BAN ' |EDIT(BAN);
-SET &I=&I+1;
END
-* In Nextel,only KB is there.
-*SET &SIZE = IF &S EQ 'H' THEN 'MB' ELSE
-*IF &S EQ 'K' THEN 'KB' ELSE
-*IF &S EQ 'G' THEN 'GB' ELSE
-*IF &S EQ 'T' THEN 'TB' ELSE 'XX';
-*IF &SIZE  EQ 'XX' GOTO ERR;
-SET &SIZE = 'KB';
TABLE FILE EXT
HEADING
-INCLUDE gnrphdr.fex
-*" <55 CYCLE: &&CYCLE-&&MONTH/&&YEAR"
"    "
PRINT TYPE         AS '' IN 1
      NUM_OF_USAGE AS '' IN 26
      AIR_CH       AS '' IN 37
      AIR_MIN      AS '' IN 50
      TOLL_CH      AS '' IN 68
      TOLL_DUR_IN_MINS AS '' IN 80
      AC_CH        AS '' IN 100
-*      TAXES_AMT  AS 'Taxes'
      TOTAL_CH     AS '' IN 113
-*      CCOUNT AS 'CCOUNT'
      COMPUTE LLCCOUNT/I6=LAST CCOUNT;NOPRINT
BY NOT_BAL_IND NOPRINT
BY BAN NOPRINT
BY ABAN NOPRINT
-*BY INDX NOPRINT
BY TYPE NOPRINT
ON BAN NOSPLIT
ON NOT_BAL_IND SUBHEAD
"<BALANCE"
"        "
WHEN NOT_BAL_IND NE 'Z';

-*ON INDX SUBHEAD
-*" "
-*" <INDN"
-*"-------"
-*ON INDX SUBFOOT
-*" "
-*"Total <INDN <20 <ST.NUM_OF_USAGE  <ST.AIR_CH  <ST.AIR_MIN
-*<59<ST.TOLL_CH  <ST.TOLL_DUR_IN_MINS  <ST.AC_CH  <ST.TAXES  <ST.TOTAL_CH"


ON BAN SUBHEAD
"BAN:<BAN    NAME :<BAN_NAME "
"       "
"<27 Number <41 Air <56 Air Dur in <72 Toll <87 Toll Dur in <119 Total"
"<1 Type of Calls <27 Of Usage <41 Charges <56 Min/KB <72 Charges <87 Min/KB
<101 Ac Charges <119 Charges"
"------------- <27 -------- <41 ------- <56 ---------- <72 ------- <87 -----------
<101 ---------- <119 -------"
WHEN NOT_BAL_IND NE 'Z' AND BAN NE  999999999;
SUBHEAD
"*Grand Total - Not Processed by Bill Preparation or No Balance Handling  =
 <TCOUNT     "
"        "
WHEN NOT_BAL_IND EQ 'Z' AND BAN EQ  999999999;
SUBHEAD
"        "
"*Summary Total - <BALANCE> = <LLCCOUNT     "
"       "
WHEN NOT_BAL_IND NE 'Z' AND BAN EQ 999999999;
-*ON ABAN SUBTOTAL AS ''
ON ABAN SUBFOOT
" "
"------------------------------------------------------------------------
<+0 -----------------------------------------------------"
"<ABAN     <26 <ST.NUM_OF_USAGE  <37 <ST.AIR_CH  <50 <ST.AIR_MIN <68 <ST.TOLL_CH
 <80 <ST.TOLL_DUR_IN_MINS <100 <ST.AC_CH <113 <ST.TOTAL_CH "
"       "
ON TABLE NOTOTAL
FOOTING BOTTOM

-INCLUDE gnrpftr.fex
-*

END
-RUN

-*---------------------* Check status of REPORT section *------------------*
-*
-IF &FOCERRNUM NE 0 GOTO ERR;
-*
-INCLUDE gnrpempt.fex

-*------------------------* Display empty report text *--------------------*
-*

TABLE FILE BLHOFF
SUM
      BAN          CM
      TYPE         CM
      NUM_OF_USAGE1 CM
      AIR_CH1       CM
      AIR_MIN1      CM
      TOLL_CH1      CM
      TOLL_DUR_IN_MINS1 CM
      AC_CH1        CM
      TOTAL_CH1     CM
BY NOT_BAL_IND NOPRINT
BY BAN NOPRINT
-*BY INDX
BY TYPE NOPRINT
-*BY RAM  NOPRINT
ON TABLE SAVE AS TMSFILE
END
-RUN
-SET &TMSFILE='../'||&&TMS_NAME;
-* -- Start Change U2L ---
-*FILEDEF DDLINE DISK &TMSFILE ( LRECL 84
FILEDEF DDLIN DISK ddline1 ( LRECL 84
-* -- End Change U2L ---
-RUN
-* -- Start Change U2L ---
-*SET &FST_LINE=&&MARKET||' - Billing Handoff';
-SET &FST_LINE=&&MARKET|| (' - Billing Handoff');
-*WRITE DDLINE &FST_LINE
-WRITE DDLIN &FST_LINE
-* -- End Change U2L ---
-RUN

FILEDEF DDLINE DISK ddline2 ( LRECL 84
-RUN
-SET &TMS_LINES=&LINES+2;
-SET &LST_LINE='EOF,'||&TMS_LINES;
-WRITE DDLINE &LST_LINE
-RUN
-* -- Start Change U2L ---
unix cat ddline1 > &TMSFILE
-* -- End Change U2L ---


unix cat tmsfile.ftm >> &TMSFILE
unix cat ddline2     >> &TMSFILE
-RUN


-IF &FOCERRNUM NE 0 GOTO ERR;
-*

-END
-*-------------------* Exit focus in case of a success *---------------*
-TYPE Report  ended successfully.

-* how is it possible that there is no disconnect ??
-*
-*--------------------------* Exit returning status *----------------------*
-* Linux Migration Start Change
-IF  &UNAME_RESULT EQ 'Linux' THEN GOTO LINUX_OS;
-QUIT FOCUS 0
-* Linux Migration End Change
-*


-ERR
-EXIT
-* Linux Migration Start Change
-IF  &UNAME_RESULT EQ 'Linux' THEN GOTO LINUX_OS;
-QUIT FOCUS &FOCERRNUM
-LINUX_OS
-EXIT
-* Linux Migration End Change
 


If u guys can help.i checked for mster file and it seems ok too.


WebFOCUS, Linux
Excel, CSV
 
Posts: 62 | Registered: May 23, 2017Report This Post
Virtuoso
posted Hide Post
Genius

I go back to my original statement, it is complaining about record 35 and you have shown us 3 records. Did you try BabakNYs suggestion with the READLIMIT and RECORDLIMIT of 1?


Thank you for using Focal Point!

Chuck Wolff - Focal Point Moderator
WebFOCUS 7x and 8x, Windows, Linux All output Formats
 
Posts: 2127 | Location: Customer Support | Registered: April 12, 2005Report This Post
Virtuoso
posted Hide Post
quote:
FILEDEF BLHOFF DISK &DATA_FILE (RECFM F LRECL 84



Assuming the error occurs after this line, you have to look at the data in the file associated with &DATA_FILE. It looks like a flat txt file. If you can open it in an editor and go to line 35, you'll have to make sure the columns in BLHOFF.MAS exactly match the format they describe.

As suggested in the past, this is an advanced piece of code and you will need to debug it using -EXIT a block at a time. We'd have a hard time doing that for you without access to the data, master file and all the -INCLUDEd files you have in the code.


WebFOCUS 8206, Unix, Windows
 
Posts: 1853 | Location: New York City | Registered: December 30, 2015Report This Post
Gold member
posted Hide Post
Hi,

i tried the way u guys suggessted and found that it is failing on 2nd record of tghe file , 1st record its passing as its all 0 but wherenever we have data in 2nd record it fails.

All these fields are BCD data types.
Can u please help me with like what data type i need to use to convert it in fex file or if i need to change in mass file

Thanks in advance


WebFOCUS, Linux
Excel, CSV
 
Posts: 62 | Registered: May 23, 2017Report This Post
Virtuoso
posted Hide Post
I disagree that these are BCD data types as you have decimals in them. I would try the following in the master file


FIELDNAME=AIR_CH ,ALIAS= ,FORMAT=D11.2 ,ACTUAL=D8 ,$
FIELDNAME=AIR_MIN ,ALIAS= ,FORMAT=D16.2 ,ACTUAL=D8 ,$
FIELDNAME=TOLL_CH ,ALIAS= ,FORMAT=D11.2 ,ACTUAL=D8 ,$
FIELDNAME=TOLL_DUR_IN_MINS ,ALIAS= ,FORMAT=D16.2 ,ACTUAL=D8 ,$
FIELDNAME=AC_CH ,ALIAS= ,FORMAT=D11.2 ,ACTUAL=D8 ,$
FIELDNAME=TAXES_AMT ,ALIAS= ,FORMAT=D11.2 ,ACTUAL=D8 ,$
FIELDNAME=TOTAL_CH ,ALIAS= ,FORMAT=D13.2 ,ACTUAL=D8 ,$


Don't redefine them in the fex just use the field names in the master file.


Thank you for using Focal Point!

Chuck Wolff - Focal Point Moderator
WebFOCUS 7x and 8x, Windows, Linux All output Formats
 
Posts: 2127 | Location: Customer Support | Registered: April 12, 2005Report This Post
Gold member
posted Hide Post
Hi chuck ,

i tried testing with the way u suggessted like chnaging only mass file as below


FILE=blhoff ,SUFFIX=FIX
SEGNAME=FIRST
FIELDNAME=BAN ,ALIAS= ,FORMAT=I9 ,ACTUAL=I4 ,$
FIELDNAME=NOT_BAL_IND ,ALIAS= ,FORMAT=A1 ,ACTUAL=A1 ,$
FIELDNAME=CALL_TYPE ,ALIAS= ,FORMAT=A1 ,ACTUAL=A1 ,$
FIELDNAME=FILLER ,ALIAS= ,FORMAT=A1 ,ACTUAL=A2 ,$
FIELDNAME=NUM_OF_USAGE ,ALIAS= ,FORMAT=I9 ,ACTUAL=I4 ,$
FIELDNAME=AIR_CH ,ALIAS= ,FORMAT=D11.2 ,ACTUAL=D8 ,$
FIELDNAME=AIR_MIN ,ALIAS= ,FORMAT=D16.2 ,ACTUAL=D8 ,$
FIELDNAME=TOLL_CH ,ALIAS= ,FORMAT=DP11.2 ,ACTUAL=D8 ,$
FIELDNAME=TOLL_DUR_IN_MINS ,ALIAS= ,FORMAT=DP16.2 ,ACTUAL=D8 ,$
FIELDNAME=AC_CH ,ALIAS= ,FORMAT=DP11.2 ,ACTUAL=D8 ,$
FIELDNAME=TAXES_AMT ,ALIAS= ,FORMAT=D11.22 ,ACTUAL=D8 ,$
FIELDNAME=TOTAL_CH ,ALIAS= ,FORMAT=D13.2 ,ACTUAL=D8 ,$
FIELDNAME=BAN_NAME ,ALIAS= ,FORMAT=A30 ,ACTUAL=A30 ,$

$Total Length:98

and commented the redefining part from script but still has same format conversion error


WebFOCUS, Linux
Excel, CSV
 
Posts: 62 | Registered: May 23, 2017Report This Post
Gold member
posted Hide Post
below is my fex file

  

-SET &ECHO=ALL;
-*
-*
-SET &&MARKET=FGETENV(10,'TLG_MARKET',3,'A3');
-*
-*
-*---------------* Define the input and output file names *-----------------*
-*
-* Linux Migration Start Change
-SET &WORKDIR=FGETENV(128,'TLG_SHORTNAME_DIR',128,'A128');
-SET &UNAME_RESULT = FGETENV(12,'UNAME_RESULT',20,'A20');
-* Linux Migration End Change

-SET DATA_NAME = FGETENV(14,'EXT_SHORT_NAME',20,'A20');
-* Linux Migration Start Change
-SET DATA_FILE = (&WORKDIR || '/'||&DATA_NAME);
-IF  &UNAME_RESULT EQ 'Linux' THEN GOTO L1556551 ;
-SET DATA_FILE = ('../'||&DATA_NAME);
-L1556551

-* Linux Migration End Change
-TYPE file data name is   &DATA_NAME
-SET REP_NAME  = FGETENV(14,'LAY_SHORT_NAME',20,'A20');
-TYPE  file report name is &REP_NAME
-* Linux Migration Start Change
-SET &&REP_FILE  = (&WORKDIR || '/'||&REP_NAME);
-IF  &UNAME_RESULT EQ 'Linux' THEN GOTO L1556631 ;
-SET &&REP_FILE  = ('../'||&REP_NAME);
-L1556631

-* Linux Migration End Change
-*
-*----* Getting report's parameters *--------------------------------*
-SET &&CYCLE= FGETENV(9,'BL_CYC_CD',4,'A4');
-SET &&MONTH= FGETENV(10,'BL_CYC_MON',2,'A2');
-SET &&YEAR= FGETENV(11,'BL_CYC_YEAR',4,'A4');
-SET &MARKET = FGETENV(12,'TLG_MARKETID',3,'A3');
-*----* Set report parameters *------------------------------------*
-SET &I=1;
-SET &&APPARTXT.&I = 'CYCLE: ';
-SET &&APPARVAL.&I = &&CYCLE;

-SET &I=2;
-SET &&APPARTXT.&I = 'MONTH: ';
-SET &&APPARVAL.&I = &&MONTH;
-SET &I=3;
-SET &&APPARTXT.&I = 'YEAR: ';
-SET &&APPARVAL.&I = &&YEAR;
-*
-*------------------* Define the Report Header *----------------------------*
-SET &REPCODE='BLHO-01-HND';
-SET &REPNAME='Billing Handoff Report';

-*-----------* Define the Indicator for data size (kb/mb/gb/tb) *------- ---*
-*INCLUDE defuom.fex
-*----------------------------------------------------------------------

FILEDEF OFFLINE DISK &&REP_FILE
OFFLINE
-*SET PANEL 250
-INCLUDE gnrpdef.fex
-*
-*------------------------* Define input file *-----------------------------*
-*
FILEDEF BLHOFF DISK &DATA_FILE (RECFM F  LRECL 98

-*
-*------------------* Initialization of parameters *------------------------*
DEFINE FILE BLHOFF
RAM/A1=DECODE CALL_TYPE( H '1' R '2' E '3' Z '4' G '5' B '6' F '7' );
TYPE/A15=DECODE CALL_TYPE( H 'HOME MSG '
                           R 'ROAMING MSG '
                           E 'EXT. HOME MSG '
                           Z 'ZONED MSG '
                           G 'HOME  MSG '
                           B 'ROAMING  MSG '
                           F 'EXT. HOME  MSG ' );

BALANCE/A35=DECODE NOT_BAL_IND (N 'No Balance  Handling             '
                                Y 'Not Processed by Bill Preparation');
INDX/A2=IF (CALL_TYPE EQ 'H') OR (CALL_TYPE EQ 'R') OR
(CALL_TYPE EQ 'E') OR (CALL_TYPE EQ 'Z') THEN 'AV' ELSE 'BD' ;
IND1/A1='Z';
BAN1/I9=999999999;
CM/A1=',';
NUM_OF_USAGE1/I9=NUM_OF_USAGE;
-*AIR_CH1/P12.2=AIR_CH;
-*AIR_MIN1/P12=AIR_MIN;
-*TOLL_CH1/P12.2=TOLL_CH;
-*TOLL_DUR_IN_MINS1/P12=TOLL_DUR_IN_MINS;
-*AC_CH1/P12.2=AC_CH;
-*TOTAL_CH1/P12.2=TOTAL_CH;
END
TABLE FILE BLHOFF
SUM
      NUM_OF_USAGE
      AIR_CH
      AIR_MIN
      TOLL_CH
      TOLL_DUR_IN_MINS
      AC_CH
-*      TAXES_AMT
      TOTAL_CH
BAN_NAME
BY NOT_BAL_IND
BY BAN
-*BY INDX
BY TYPE
-*BY RAM
ON TABLE HOLD AS EXT
END
-RUN
FILEDEF EXT DISK ext.ftm (APPEND
-RUN
TABLE FILE BLHOFF
SUM
      NUM_OF_USAGE
      AIR_CH
      AIR_MIN
      TOLL_CH
      TOLL_DUR_IN_MINS
      AC_CH
-*      TAXES_AMT
      TOTAL_CH
BAN_NAME
BY NOT_BAL_IND
BY BAN1
-*BY INDX
BY TYPE
-*BY RAM
ON TABLE SAVE AS EXT
END
-RUN
TABLE FILE BLHOFF
SUM
      NUM_OF_USAGE
      AIR_CH
      AIR_MIN
      TOLL_CH
      TOLL_DUR_IN_MINS
      AC_CH
-*      TAXES_AMT
      TOTAL_CH
BAN_NAME
BY IND1
BY BAN1
-*BY INDX
BY TYPE
-*BY RAM
ON TABLE SAVE AS EXT
END
-RUN

DEFINE FILE EXT
-*INDN/A10=IF INDX EQ 'AV' THEN 'Voice' ELSE 'GPRS';
BALANCE/A35=DECODE NOT_BAL_IND (N 'No Balance  Handling             '
                                Y 'Not Processed by Bill Preparation');
-*LCCOUNT/I6 = IF NOT_BAL_IND EQ 'N' OR 'Y' THEN LAST CCOUNT;
-*SET &I=0;
CCOUNT/I6  =IF NOT_BAL_IND NE LAST NOT_BAL_IND THEN 1  ELSE
IF BAN EQ 999999999 THEN CCOUNT ELSE IF BAN NE LAST BAN THEN CCOUNT + 1;
TCOUNT/I6  =IF BAN EQ 999999999 THEN TCOUNT ELSE
IF BAN NE LAST BAN THEN TCOUNT + 1 ELSE TCOUNT;
ABAN/A19=IF BAN EQ 999999999 THEN 'TOTAL ' ELSE  'TOTAL BAN ' |EDIT(BAN);
-SET &I=&I+1;
END
-* In Nextel,only KB is there.
-*SET &SIZE = IF &S EQ 'H' THEN 'MB' ELSE
-*IF &S EQ 'K' THEN 'KB' ELSE
-*IF &S EQ 'G' THEN 'GB' ELSE
-*IF &S EQ 'T' THEN 'TB' ELSE 'XX';
-*IF &SIZE  EQ 'XX' GOTO ERR;
-SET &SIZE = 'KB';
TABLE FILE EXT
HEADING
-INCLUDE gnrphdr.fex
-*" <55 CYCLE: &&CYCLE-&&MONTH/&&YEAR"
"    "
PRINT TYPE         AS '' IN 1
      NUM_OF_USAGE AS '' IN 26
      AIR_CH       AS '' IN 37
      AIR_MIN      AS '' IN 50
      TOLL_CH      AS '' IN 68
      TOLL_DUR_IN_MINS AS '' IN 80
      AC_CH        AS '' IN 100
-*      TAXES_AMT  AS 'Taxes'
      TOTAL_CH     AS '' IN 113
-*      CCOUNT AS 'CCOUNT'
      COMPUTE LLCCOUNT/I6=LAST CCOUNT;NOPRINT
BY NOT_BAL_IND NOPRINT
BY BAN NOPRINT
BY ABAN NOPRINT
-*BY INDX NOPRINT
BY TYPE NOPRINT
ON BAN NOSPLIT
ON NOT_BAL_IND SUBHEAD
"<BALANCE"
"        "
WHEN NOT_BAL_IND NE 'Z';

-*ON INDX SUBHEAD
-*" "
-*" <INDN"
-*"-------"
-*ON INDX SUBFOOT
-*" "
-*"Total <INDN <20 <ST.NUM_OF_USAGE  <ST.AIR_CH  <ST.AIR_MIN
-*<59<ST.TOLL_CH  <ST.TOLL_DUR_IN_MINS  <ST.AC_CH  <ST.TAXES  <ST.TOTAL_CH"


ON BAN SUBHEAD
"BAN:<BAN    NAME :<BAN_NAME "
"       "
"<27 Number <41 Air <56 Air Dur in <72 Toll <87 Toll Dur in <119 Total"
"<1 Type of Calls <27 Of Usage <41 Charges <56 Min/KB <72 Charges <87 Min/KB
<101 Ac Charges <119 Charges"
"------------- <27 -------- <41 ------- <56 ---------- <72 ------- <87 -----------
<101 ---------- <119 -------"
WHEN NOT_BAL_IND NE 'Z' AND BAN NE  999999999;
SUBHEAD
"*Grand Total - Not Processed by Bill Preparation or No Balance Handling  =
 <TCOUNT     "
"        "
WHEN NOT_BAL_IND EQ 'Z' AND BAN EQ  999999999;
SUBHEAD
"        "
"*Summary Total - <BALANCE> = <LLCCOUNT     "
"       "
WHEN NOT_BAL_IND NE 'Z' AND BAN EQ 999999999;
-*ON ABAN SUBTOTAL AS ''
ON ABAN SUBFOOT
" "
"------------------------------------------------------------------------
<+0 -----------------------------------------------------"
"<ABAN     <26 <ST.NUM_OF_USAGE  <37 <ST.AIR_CH  <50 <ST.AIR_MIN <68 <ST.TOLL_CH
 <80 <ST.TOLL_DUR_IN_MINS <100 <ST.AC_CH <113 <ST.TOTAL_CH "
"       "
ON TABLE NOTOTAL
FOOTING BOTTOM

-INCLUDE gnrpftr.fex
-*

END
-RUN

-*---------------------* Check status of REPORT section *------------------*
-*
-IF &FOCERRNUM NE 0 GOTO ERR;
-*
-INCLUDE gnrpempt.fex

-*------------------------* Display empty report text *--------------------*
-*

TABLE FILE BLHOFF
SUM
      BAN          CM
      TYPE         CM
      NUM_OF_USAGE1 CM
      AIR_CH1       CM
      AIR_MIN1      CM
      TOLL_CH1      CM
      TOLL_DUR_IN_MINS1 CM
      AC_CH1        CM
      TOTAL_CH1     CM
BY NOT_BAL_IND NOPRINT
BY BAN NOPRINT
-*BY INDX
BY TYPE NOPRINT
-*BY RAM  NOPRINT
ON TABLE SAVE AS TMSFILE
END
-RUN
-SET &TMSFILE='../'||&&TMS_NAME;
-* -- Start Change U2L ---
-*FILEDEF DDLINE DISK &TMSFILE ( LRECL 84
FILEDEF DDLIN DISK ddline1 ( LRECL 84
-* -- End Change U2L ---
-RUN
-* -- Start Change U2L ---
-*SET &FST_LINE=&&MARKET||' - Billing Handoff';
-SET &FST_LINE=&&MARKET|| (' - Billing Handoff');
-*WRITE DDLINE &FST_LINE
-WRITE DDLIN &FST_LINE
-* -- End Change U2L ---
-RUN

FILEDEF DDLINE DISK ddline2 ( LRECL 84
-RUN
-SET &TMS_LINES=&LINES+2;
-SET &LST_LINE='EOF,'||&TMS_LINES;
-WRITE DDLINE &LST_LINE
-RUN
-* -- Start Change U2L ---
unix cat ddline1 > &TMSFILE
-* -- End Change U2L ---


unix cat tmsfile.ftm >> &TMSFILE
unix cat ddline2     >> &TMSFILE
-RUN


-IF &FOCERRNUM NE 0 GOTO ERR;
-*

-END
-*-------------------* Exit focus in case of a success *---------------*
-TYPE Report  ended successfully.

-* how is it possible that there is no disconnect ??
-*
-*--------------------------* Exit returning status *----------------------*
-* Linux Migration Start Change
-IF  &UNAME_RESULT EQ 'Linux' THEN GOTO LINUX_OS;
-QUIT FOCUS 0
-* Linux Migration End Change
-*


-ERR
-EXIT
-* Linux Migration Start Change
-IF  &UNAME_RESULT EQ 'Linux' THEN GOTO LINUX_OS;
-QUIT FOCUS &FOCERRNUM
-LINUX_OS
-EXIT
-* Linux Migration End Change



WebFOCUS, Linux
Excel, CSV
 
Posts: 62 | Registered: May 23, 2017Report This Post
Virtuoso
posted Hide Post
Like others have suggested, you ought to go to the person who created this master file and ask them if they can sample the data. This can be done in App Studio or Reporting Serve console. The code you posted will be of little use if the master file isn't working to begin with.


WebFOCUS 8206, Unix, Windows
 
Posts: 1853 | Location: New York City | Registered: December 30, 2015Report This Post
Virtuoso
posted Hide Post
Genius

I agree with Babak, you need to work with whoever has created this master file and have them redo it. If it still doesn't work you need to open a case with techsupport and get them to help you...


Thank you for using Focal Point!

Chuck Wolff - Focal Point Moderator
WebFOCUS 7x and 8x, Windows, Linux All output Formats
 
Posts: 2127 | Location: Customer Support | Registered: April 12, 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     [CLOSED] FOC1346) : FORMAT ERROR: Record 35 , Column 28

Copyright © 1996-2020 Information Builders