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] Leading spaces in FORMAT DOC

Read-Only Read-Only Topic
Go
Search
Notify
Tools
[SOLVED] Leading spaces in FORMAT DOC
 Login/Join
 
Member
posted
Hello, We need to provide a file to a vendor without the leading spaces in the DOC format. Any suggestions?

Here is my fex (below). Thanks. (EDIT: Looks like the copy and paste may have changed a few lines?)

Doug

JOIN CLEAR *
SET ALL = PASS
JOIN SFRSTCR_PIDM IN SFRSTCR TO
SPRIDEN_PIDM IN SPRIDEN AS A
END
JOIN SFRSTCR_TERM_CODE AND SFRSTCR_CRN IN SFRSTCR TO
SSBSECT_TERM_CODE AND SSBSECT_CRN IN SSBSECT AS B
END
JOIN SSBSECT_SUBJ_CODE AND SSBSECT_CRSE_NUMB IN SFRSTCR
TO SZVCRSE_SUBJ_CODE AND SZVCRSE_CRSE_NUMB IN SZVCRSE AS C
END
JOIN SSBSECT_TERM_CODE AND SSBSECT_CRN IN SFRSTCR TO
SIRASGN_TERM_CODE AND SIRASGN_CRN IN SIRASGN AS D
END
JOIN SIRASGN_PIDM IN SFRSTCR TO
SPRIDEN_PIDM IN SPRIDEN AS E
END
JOIN SFRSTCR_PIDM IN SFRSTCR TO
SZVSTDN_PIDM IN SZVSTDN AS F
END
JOIN SFRSTCR_PIDM IN SFRSTCR TO
SPBPERS_PIDM IN SPBPERS AS G
END
JOIN SZVSTDN_MAJR_CODE_1 IN SFRSTCR TO
STVMAJR_CODE IN STVMAJR AS H
END
END
JOIN SSBSECT_TERM_CODE AND SSBSECT_CRN IN SFRSTCR TO ALL
SSRMEET_TERM_CODE AND SSRMEET_CRN IN SSRMEET AS I
END
JOIN SSRMEET_BLDG_CODE IN SFRSTCR TO
STVBLDG_CODE IN STVBLDG AS J
END
SET PRINT = ONLINE
SET PAGE-NUM = NOPAGE
SET NODATA = '';
DEFINE FILE SFRSTCR
TITLE/A30 = IF SSBSECT_CRSE_TITLE IS MISSING THEN SZVCRSE_TITLE
ELSE SSBSECT_CRSE_TITLE;
CREDITS/D5.2 MISSING ON = SFRSTCR_CREDIT_HR;
BTIME/A8 = IF SSRMEET_BEGIN_TIME IS MISSING THEN '' ELSE
IF SSRMEET_BEGIN_TIME FROM '0000' TO '0959' THEN EDIT(SSRMEET_BEGIN_TIME,'$ 9:99 am') ELSE IF
SSRMEET_BEGIN_TIME FROM '1000' TO '1159' THEN EDIT(SSRMEET_BEGIN_TIME,'99:99 am')
ELSE IF SSRMEET_BEGIN_TIME FROM '1200' TO '1259' THEN EDIT(SSRMEET_BEGIN_TIME,'99:99 pm')
ELSE IF SSRMEET_BEGIN_TIME LIKE '13%%' THEN EDIT(SSRMEET_BEGIN_TIME,'$$ 1:99 pm')
ELSE IF SSRMEET_BEGIN_TIME LIKE '14%%' THEN EDIT(SSRMEET_BEGIN_TIME,'$$ 2:99 pm')
ELSE IF SSRMEET_BEGIN_TIME LIKE '15%%' THEN EDIT(SSRMEET_BEGIN_TIME,'$$ 3:99 pm')
ELSE IF SSRMEET_BEGIN_TIME LIKE '16%%' THEN EDIT(SSRMEET_BEGIN_TIME,'$$ 4:99 pm')
ELSE IF SSRMEET_BEGIN_TIME LIKE '17%%' THEN EDIT(SSRMEET_BEGIN_TIME,'$$ 5:99 pm')
ELSE IF SSRMEET_BEGIN_TIME LIKE '18%%' THEN EDIT(SSRMEET_BEGIN_TIME,'$$ 6:99 pm')
ELSE IF SSRMEET_BEGIN_TIME LIKE '19%%' THEN EDIT(SSRMEET_BEGIN_TIME,'$$ 7:99 pm')
ELSE IF SSRMEET_BEGIN_TIME LIKE '20%%' THEN EDIT(SSRMEET_BEGIN_TIME,'$$ 8:99 pm')
ELSE IF SSRMEET_BEGIN_TIME LIKE '21%%' THEN ' 9'||EDIT(SSRMEET_BEGIN_TIME,'$$:99 pm')
ELSE IF SSRMEET_BEGIN_TIME LIKE '22%%' THEN EDIT(SSRMEET_BEGIN_TIME,'$$10:99 pm')
ELSE IF SSRMEET_BEGIN_TIME LIKE '23%%' THEN EDIT(SSRMEET_BEGIN_TIME,'$$11:99 pm')
ELSE SSRMEET_BEGIN_TIME;
ETIME/A8 = IF SSRMEET_END_TIME IS MISSING THEN '' ELSE IF SSRMEET_END_TIME
FROM '0000' TO '0959' THEN EDIT(SSRMEET_END_TIME,'$ 9:99 am') ELSE IF SSRMEET_END_TIME
FROM '1000' TO '1159' THEN EDIT (SSRMEET_END_TIME,'99:99 am') ELSE
IF SSRMEET_END_TIME FROM '1200' TO '1259' THEN EDIT (SSRMEET_END_TIME,'99:99 pm') ELSE
IF SSRMEET_END_TIME LIKE '13%%' THEN EDIT(SSRMEET_END_TIME,'$$ 1:99 pm')
ELSE IF SSRMEET_END_TIME LIKE '14%%' THEN EDIT(SSRMEET_END_TIME,'$$ 2:99 pm')
ELSE IF SSRMEET_END_TIME LIKE '15%%' THEN EDIT(SSRMEET_END_TIME,'$$ 3:99 pm')
ELSE IF SSRMEET_END_TIME LIKE '16%%' THEN EDIT(SSRMEET_END_TIME,'$$ 4:99 pm')
ELSE IF SSRMEET_END_TIME LIKE '17%%' THEN EDIT(SSRMEET_END_TIME,'$$ 5:99 pm')
ELSE IF SSRMEET_END_TIME LIKE '18%%' THEN EDIT(SSRMEET_END_TIME,'$$ 6:99 pm')
ELSE IF SSRMEET_END_TIME LIKE '19%%' THEN EDIT(SSRMEET_END_TIME,'$$ 7:99 pm')
ELSE IF SSRMEET_END_TIME LIKE '20%%' THEN EDIT(SSRMEET_END_TIME,'$$ 8:99 pm')
ELSE IF SSRMEET_END_TIME LIKE '21%%' THEN ' 9'||EDIT(SSRMEET_END_TIME,'$$:99 pm')
ELSE IF SSRMEET_END_TIME LIKE '22%%' THEN EDIT(SSRMEET_END_TIME,'$$10:99 pm')
ELSE IF SSRMEET_END_TIME LIKE '23%%' THEN EDIT(SSRMEET_END_TIME,'$$11:99 pm')
ELSE SSRMEET_END_TIME;
TIMES/A17 = IF BTIME IS NOT MISSING THEN BTIME||'-'||ETIME ELSE '';
SECTIN/A4 = IF SSBSECT_SEQ_NUMB
IS NOT '0'
THEN SSBSECT_SEQ_NUMB
ELSE '';
THU/A2 = IF SSRMEET_THU_DAY IS 'R' THEN 'Th' ELSE '';
SECTION/A4 = SECTIN;
SUBJECT/A4 = SSBSECT_SUBJ_CODE;
NUMBER/A6 = SSBSECT_CRSE_NUMB;
STVBLDG_DESC/A20 = EDIT(STVBLDG_DESC,'99999999999999999999');
STVBLDG_DES/A40 = STVBLDG_DESC||(' '|SSRMEET_ROOM_CODE);
ELAST_NAME/A20 = IF ESPRIDEN_LAS IS '' THEN
'TBA' ELSE
EDIT(ESPRIDEN_FIR,'9')||('. '|
EDIT(ESPRIDEN_LAS,'999999999999999'));
TERM/A12= IF SFRSTCR_TERM_CODE LIKE '%09' THEN EDIT(SFRSTCR_TERM_CODE,
'FALL 9999$$') ELSE
IF SFRSTCR_TERM_CODE LIKE '%01' THEN
EDIT(SFRSTCR_TERM_CODE,'SPRING 9999$$') ELSE IF SFRSTCR_TERM_CODE LIKE '%06'
THEN EDIT(SFRSTCR_TERM_CODE,'SUMMER 9999$$') ELSE IF SFRSTCR_TERM_CODE
LIKE '%12' THEN EDIT(SFRSTCR_TERM_CODE,'WINTER 9999$$') ELSE
'';
COURSE/A48 = SUBJECT|' '|NUMBER|' '|SECTION|' '|TITLE;
CRITE/A30 = IF SFRSTCR_TERM_CODE GE '999999' THEN 'Crite Sheet' ELSE '';
END
TABLE FILE SFRSTCR
HEADING
"WRITE SFRSTCR_PIDM NOPRINT
SSRMEET_MON_DAY AS '' SSRMEET_TUE_DAY AS '' SSRMEET_WED_DAY AS ''
THU AS '' SSRMEET_FRI_DAY AS ''
TIMES AS ''
SSRMEET_BLDG_CODE AS '' SSRMEET_ROOM_CODE AS '' ELAST_NAME AS ''
SFRSTCR_TERM_CODE NOPRINT SFRSTCR_CRN NOPRINT
CRITE AS ''
BY SFRSTCR_PIDM NOPRINT
BY SSBSECT_PTRM_CODE NOPRINT
BY ASPRIDEN_ID NOPRINT
BY COURSE AS ''
BY CREDITS NOPRINT
BY SFRSTCR_GRDE_CODE_MID AS 'MID-TERM,GRADE' NOPRINT
BY SSBSECT_SUBJ_CODE NOPRINT
BY SSBSECT_CRSE_NUMB NOPRINT
BY SSBSECT_SEQ_NUMB NOPRINT
BY SSRMEET_MON_DAY NOPRINT
BY SSRMEET_TUE_DAY NOPRINT
BY SSRMEET_WED_DAY NOPRINT
BY SSRMEET_THU_DAY NOPRINT
BY SSRMEET_FRI_DAY NOPRINT
BY SSRMEET_BEGIN_TIME NOPRINT
ON ASPRIDEN_ID PAGE-BREAK SUBFOOT
"**********"
-*IF SFRSTCR_PIDM EQ '979324' OR '992867' OR '788256'
IF SSBSECT_SSTS_CODE IS 'A'
WHERE SFRSTCR_RSTS_CODE NE 'DD' OR 'DE'
IF SFRSTCR_TERM_CODE IS '201809'
WHERE ASPRIDEN_CHANGE_IND IS MISSING
WHERE ESPRIDEN_CHANGE_IND IS MISSING
WHERE SZVSTDN_LEVL_CODE EQ '01'
ON TABLE PCHOLD FORMAT DOC
END
-RUN
-QUIT

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


WebFOCUS 7.6
Windows, All Outputs
 
Posts: 5 | Registered: October 22, 2012Report This Post
Virtuoso
posted Hide Post
Doug,
You can use the TRIMV function to remove either leading, trailing or both spaces as the last step after all your EDIT manipulations.

But you also add leading space (right before the "1") yourself by doing that : EDIT(SSRMEET_BEGIN_TIME,'$$ 1:99 pm')


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
Member
posted Hide Post
Alas, I tried that to no avail. I think the issue is with the DOC format. It puts two spaces before each row.

For example:
CHEM 311 Physical Chemistry
GIS 401 JK MC 401: Senior Project I
HIST 127 Intro Modern Japanese History
HIST 2238 Africa and the Indian Ocean

becomes:
xxCHEM 311 Physical Chemistry
xxGIS 401 JK MC 401: Senior Project I
xxHIST 127 Intro Modern Japanese
xxHistoryHIST 2238 Africa and the Indian

(where xx is two blank spaces) Those leading spaces are preventing my vendor from consuming the file. I've tried ALPHA format, but that strips the header and footer data. I may have to redo the fex for that format, it seems.


WebFOCUS 7.6
Windows, All Outputs
 
Posts: 5 | Registered: October 22, 2012Report This Post
Virtuoso
posted Hide Post
Have you tried FORMAT COMT?

https://webfocusinfocenter.inf...ce/rc_formats116.htm


WebFOCUS 8206, Unix, Windows
 
Posts: 1853 | Location: New York City | Registered: December 30, 2015Report This Post
Member
posted Hide Post
No luck. We had to do what we call a SQL wrapper to eliminate the header and format the file the way the vendor wants it. It worked. Took too much time though.

SET SQLENGINE=SQLORA
SQL PREPARE MAXIENT_SCHED_QUERY FROM
select DISTINCT sfrstcr_pidm SFRSTCR_PIDM,
sfrstcr_term_code SFRSTCR_TERM_CODE,
sfrstcr_crn SFRSTCR_CRN,
sfrstcr_credit_hr SFRSTCR_CREDIT_HR,
sfrstcr_grde_code_mid SFRSTCR_GRDE_CODE_MID,
sfrstcr_rsts_code SFRSTCR_RSTS_CODE,
'B' SFRSTCR_SEQ,
null SFRSTCR_FILLER,
SSBSECT_SUBJ_CODE SSBSECT_SUBJ_CODE,
SSBSECT_CRSE_NUMB SSBSECT_CRSE_NUMB,
SZVCRSE_TITLE SZVCRSE_TITLE
from saturn.sfrstcr,
SATURN.SSBSECT,
SATURN.SZVCRSE
where SSBSECT_CRSE_NUMB = SZVCRSE_CRSE_NUMB
AND SSBSECT_SUBJ_CODE = SZVCRSE_SUBJ_CODE
AND SFRSTCR_CRN = SSBSECT_CRN
AND SFRSTCR_TERM_CODE = SSBSECT_TERM_CODE
AND SFRSTCR_RSTS_CODE NOT IN ('DD', 'DE')
AND SFRSTCR_TERM_CODE >= '201809'
union
select szviden_pidm,
sfrstcr_term_code,
-*
-* NOTE
-* CHOOSE A GENERIC COURSE CRN FOR THE SEMESTER WITH NO MEETING SCHEDULE FOR A SINGLE ROW RETURN, I USED A SENIOR PROJECT COURSE
-* THE OUTPUT REQUIRES A SINGLE ROW RETURN FOR THE FILLER ROW
-*
max('92474'),
max(0),
max(null),
max('xx'),
'A',
szviden_id,
max(null),
max(null),
max(null)
from saturn.szviden,saturn.sfrstcr
where szviden_pidm = sfrstcr_pidm
and sfrstcr_term_code >= '201809'
AND SFRSTCR_RSTS_CODE NOT IN ('DD', 'DE')
group by szviden_pidm,szviden_id,sfrstcr_term_code, 7
union
select szviden_pidm,
sfrstcr_term_code,
-*
-* NOTE
-* CHOOSE A GENERIC COURSE CRN FOR THE SEMESTER WITH NO MEETING SCHEDULE FOR A SINGLE ROW RETURN, I USED A SENIOR PROJECT COURSE
-* THE OUTPUT REQUIRES A SINGLE ROW RETURN FOR THE FILLER ROW
-*
max('92474'),
max(0),
max(null),
max('xx'),
'C',
'**********',
max(null),
max(null),
max(null)
from saturn.szviden,saturn.sfrstcr
where szviden_pidm = sfrstcr_pidm
and sfrstcr_term_code >= '201809'
AND SFRSTCR_RSTS_CODE NOT IN ('DD', 'DE')
group by szviden_pidm,szviden_id,sfrstcr_term_code, 7
order by 1,2,7
END
SQL EXECUTE MAXIENT_SCHED_QUERY;

-**********************************************************
TABLE
ON TABLE HOLD
END
-RUN
-**********************************************************

JOIN CLEAR *
SET ALL = PASS

JOIN SFRSTCR_TERM_CODE AND SFRSTCR_CRN IN HOLD TO
SSBSECT_TERM_CODE AND SSBSECT_CRN IN SSBSECT AS B
END

JOIN SFRSTCR_PIDM IN HOLD TO
SPRIDEN_PIDM IN SPRIDEN AS A
END


-*JOIN SSBSECT_SUBJ_CODE AND SSBSECT_CRSE_NUMB IN HOLD
-*TO ALL SZVCRSE_SUBJ_CODE AND SZVCRSE_CRSE_NUMB IN SZVCRSE AS C
-*END

JOIN SSBSECT_TERM_CODE AND SSBSECT_CRN IN HOLD TO
SIRASGN_TERM_CODE AND SIRASGN_CRN IN SIRASGN AS D
END
JOIN SIRASGN_PIDM IN HOLD TO
SPRIDEN_PIDM IN SPRIDEN AS E
END
JOIN SFRSTCR_PIDM IN HOLD TO
SZVSTDN_PIDM IN SZVSTDN AS F
END
JOIN SFRSTCR_PIDM IN HOLD TO
SPBPERS_PIDM IN SPBPERS AS G
END
JOIN SZVSTDN_MAJR_CODE_1 IN HOLD TO
STVMAJR_CODE IN STVMAJR AS H
END
END
JOIN SSBSECT_TERM_CODE AND SSBSECT_CRN IN HOLD TO ALL
SSRMEET_TERM_CODE AND SSRMEET_CRN IN SSRMEET AS I
END
JOIN SSRMEET_BLDG_CODE IN HOLD TO
STVBLDG_CODE IN STVBLDG AS J
END


SET PRINT = ONLINE
SET PAGE-NUM = NOPAGE
SET NODATA = '';
-*SET ALL = PASS

DEFINE FILE HOLD
TITLE/A1000 = IF SSBSECT_CRSE_TITLE IS MISSING THEN SZVCRSE_TITLE
ELSE SSBSECT_CRSE_TITLE;
END



DEFINE FILE HOLD
ZTITLE/A30 = EDIT(SZVCRSE_TITLE,'999999999999999999999999999999');
TITLE/A30 = IF SSBSECT_CRSE_TITLE IS MISSING THEN ZTITLE
ELSE SSBSECT_CRSE_TITLE;
CREDITS/D5.2 MISSING ON = SFRSTCR_CREDIT_HR;
BTIME/A8 = IF SSRMEET_BEGIN_TIME IS MISSING THEN '' ELSE
IF SSRMEET_BEGIN_TIME FROM '0000' TO '0959' THEN EDIT(SSRMEET_BEGIN_TIME,'$ 9:99 am') ELSE IF
SSRMEET_BEGIN_TIME FROM '1000' TO '1159' THEN EDIT(SSRMEET_BEGIN_TIME,'99:99 am')
ELSE IF SSRMEET_BEGIN_TIME FROM '1200' TO '1259' THEN EDIT(SSRMEET_BEGIN_TIME,'99:99 pm')
ELSE IF SSRMEET_BEGIN_TIME LIKE '13%%' THEN EDIT(SSRMEET_BEGIN_TIME,'$$ 1:99 pm')
ELSE IF SSRMEET_BEGIN_TIME LIKE '14%%' THEN EDIT(SSRMEET_BEGIN_TIME,'$$ 2:99 pm')
ELSE IF SSRMEET_BEGIN_TIME LIKE '15%%' THEN EDIT(SSRMEET_BEGIN_TIME,'$$ 3:99 pm')
ELSE IF SSRMEET_BEGIN_TIME LIKE '16%%' THEN EDIT(SSRMEET_BEGIN_TIME,'$$ 4:99 pm')
ELSE IF SSRMEET_BEGIN_TIME LIKE '17%%' THEN EDIT(SSRMEET_BEGIN_TIME,'$$ 5:99 pm')
ELSE IF SSRMEET_BEGIN_TIME LIKE '18%%' THEN EDIT(SSRMEET_BEGIN_TIME,'$$ 6:99 pm')
ELSE IF SSRMEET_BEGIN_TIME LIKE '19%%' THEN EDIT(SSRMEET_BEGIN_TIME,'$$ 7:99 pm')
ELSE IF SSRMEET_BEGIN_TIME LIKE '20%%' THEN EDIT(SSRMEET_BEGIN_TIME,'$$ 8:99 pm')
ELSE IF SSRMEET_BEGIN_TIME LIKE '21%%' THEN ' 9'||EDIT(SSRMEET_BEGIN_TIME,'$$:99 pm')
ELSE IF SSRMEET_BEGIN_TIME LIKE '22%%' THEN EDIT(SSRMEET_BEGIN_TIME,'$$10:99 pm')
ELSE IF SSRMEET_BEGIN_TIME LIKE '23%%' THEN EDIT(SSRMEET_BEGIN_TIME,'$$11:99 pm')
ELSE SSRMEET_BEGIN_TIME;
ETIME/A8 = IF SSRMEET_END_TIME IS MISSING THEN '' ELSE IF SSRMEET_END_TIME
FROM '0000' TO '0959' THEN EDIT(SSRMEET_END_TIME,'$ 9:99 am') ELSE IF SSRMEET_END_TIME
FROM '1000' TO '1159' THEN EDIT (SSRMEET_END_TIME,'99:99 am') ELSE
IF SSRMEET_END_TIME FROM '1200' TO '1259' THEN EDIT (SSRMEET_END_TIME,'99:99 pm') ELSE
IF SSRMEET_END_TIME LIKE '13%%' THEN EDIT(SSRMEET_END_TIME,'$$ 1:99 pm')
ELSE IF SSRMEET_END_TIME LIKE '14%%' THEN EDIT(SSRMEET_END_TIME,'$$ 2:99 pm')
ELSE IF SSRMEET_END_TIME LIKE '15%%' THEN EDIT(SSRMEET_END_TIME,'$$ 3:99 pm')
ELSE IF SSRMEET_END_TIME LIKE '16%%' THEN EDIT(SSRMEET_END_TIME,'$$ 4:99 pm')
ELSE IF SSRMEET_END_TIME LIKE '17%%' THEN EDIT(SSRMEET_END_TIME,'$$ 5:99 pm')
ELSE IF SSRMEET_END_TIME LIKE '18%%' THEN EDIT(SSRMEET_END_TIME,'$$ 6:99 pm')
ELSE IF SSRMEET_END_TIME LIKE '19%%' THEN EDIT(SSRMEET_END_TIME,'$$ 7:99 pm')
ELSE IF SSRMEET_END_TIME LIKE '20%%' THEN EDIT(SSRMEET_END_TIME,'$$ 8:99 pm')
ELSE IF SSRMEET_END_TIME LIKE '21%%' THEN ' 9'||EDIT(SSRMEET_END_TIME,'$$:99 pm')
ELSE IF SSRMEET_END_TIME LIKE '22%%' THEN EDIT(SSRMEET_END_TIME,'$$10:99 pm')
ELSE IF SSRMEET_END_TIME LIKE '23%%' THEN EDIT(SSRMEET_END_TIME,'$$11:99 pm')
ELSE SSRMEET_END_TIME;
TIMES/A17 = IF BTIME IS NOT MISSING THEN BTIME||'-'||ETIME ELSE '';
SECTIN/A4 = IF SSBSECT_SEQ_NUMB
IS NOT '0'
THEN SSBSECT_SEQ_NUMB
ELSE ' ';
THU/A2 = IF SSRMEET_THU_DAY IS 'R' THEN 'Th' ELSE '';
SECTION/A5 = EDIT(SECTIN,'99999');
SUBJECT/A5 = EDIT(SSBSECT_SUBJ_CODE,'99999');
NUMBER/A5 = EDIT(SSBSECT_CRSE_NUMB,'99999');
STVBLDG_DESC/A20 = EDIT(STVBLDG_DESC,'99999999999999999999');
STVBLDG_DES/A40 = STVBLDG_DESC||(' '|SSRMEET_ROOM_CODE);
ELAST_NAME/A20 = IF ESPRIDEN_LAS IS '' THEN
'TBA' ELSE
EDIT(ESPRIDEN_FIR,'9')||('. '|
EDIT(ESPRIDEN_LAS,'999999999999999'));
TERM/A12= IF SFRSTCR_TERM_CODE LIKE '%09' THEN EDIT(SFRSTCR_TERM_CODE,
'FALL 9999$$') ELSE
IF SFRSTCR_TERM_CODE LIKE '%01' THEN
EDIT(SFRSTCR_TERM_CODE,'SPRING 9999$$') ELSE IF SFRSTCR_TERM_CODE LIKE '%06'
THEN EDIT(SFRSTCR_TERM_CODE,'SUMMER 9999$$') ELSE IF SFRSTCR_TERM_CODE
LIKE '%12' THEN EDIT(SFRSTCR_TERM_CODE,'WINTER 9999$$') ELSE
'';
COURSE/A50 = SUBJECT|NUMBER|SECTION|TITLE;
CRITE/A30 = IF SFRSTCR_TERM_CODE GE '999999' THEN 'Crite Sheet' ELSE '';
SCHEDLINE/A200 = IF SFRSTCR_SEQ EQ 'A' OR 'C' THEN SFRSTCR_FILLER||' ' ELSE
COURSE|' '|SSRMEET_MON_DAY|SSRMEET_TUE_DAY|SSRMEET_WED_DAY|
THU|SSRMEET_FRI_DAY|' '|TIMES|' '|SSRMEET_BLDG_CODE|' '|SSRMEET_ROOM_CODE|
' '|ELAST_NAME;
END

TABLE FILE HOLD
PRINT SCHEDLINE
IF SSBSECT_SSTS_CODE IS 'A'
WHERE SFRSTCR_RSTS_CODE NE 'DD' OR 'DE'
WHERE SFRSTCR_TERM_CODE IS '201809'
WHERE ASPRIDEN_CHANGE_IND IS MISSING
WHERE ESPRIDEN_CHANGE_IND IS MISSING
WHERE SZVSTDN_LEVL_CODE EQ '01'
BY ASPRIDEN_ID NOPRINT
BY SFRSTCR_SEQ NOPRINT
ON TABLE PCHOLD FORMAT ALPHA
END
-EXIT


WebFOCUS 7.6
Windows, All Outputs
 
Posts: 5 | Registered: October 22, 2012Report This Post
Expert
posted Hide Post
A lot easier to have used an alternate format as suggested by Babak - except use DFIX not COMT -

A little tip when asking questons on the forum, show an example that utilises a sample table (such as CAR, GGSALES, EMPLOYEE, RETAIL etc.). That way, anyone should be able to run your code and see what you mean.

TABLE FILE CAR
  SUM RCOST
      DCOST
   BY COUNTRY
   BY CAR
   BY MODEL
ON TABLE PCHOLD FORMAT DFIX HEADER YES DELIMITER ' '
END



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
  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] Leading spaces in FORMAT DOC

Copyright © 1996-2020 Information Builders