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.
Hello All I need to repeat a value for every row For example I have column called flda, it has a value , I need to repeat this value for all other rows in fldb example flda fldb row1 0001 45 row2 0002 0 row3 0003 0 row4 0004 0 ... row99 0099 0
in the above example I will need fldb with the value of 45 for all rows
ThanksThis message has been edited. Last edited by: FP Mod Chuck,
Prod/Dev/Test: WF 8.1.5 on (Windows Server 2012 R2 ) SandBox: WebFocus Server 8.1.5 on Windows Server 2008 R2 WebFOCUS App Studio 8.1.5 and Developer Studio 8.1.5 on Windows 7
Posts: 134 | Location: USA | Registered: August 21, 2008
DEFINE FILE CAR
SRT/I1=0;
END
TABLE FILE CAR
PRINT SALES
COMPUTE FST/D12.2M = PARTITION_AGGR(SALES, SRT, B, C, FST);
BY SRT
BY COUNTRY
WHERE COUNTRY EQ 'W GERMANY'
ON TABLE SET PAGE NOLEAD
END
Thank You I tried that , for some reason it does not like
DEFINE FILE CAR
SRT/I1=0;
END
TABLE FILE CAR
PRINT SALES
COMPUTE FST/D12.2M = PARTITION_AGGR(SALES, SRT, -1, C, FST);
BY SRT
BY COUNTRY
WHERE COUNTRY EQ 'W GERMANY'
ON TABLE SET PAGE NOLEAD
END
0 ERROR AT OR NEAR LINE 9 IN PROCEDURE ADHOCRQ FOCEXEC *
(FOC258) FIELDNAME OR COMPUTATIONAL ELEMENT NOT RECOGNIZED: C
(FOC009) INCOMPLETE REQUEST STATEMENT
BYPASSING TO END OF COMMAND
Prod/Dev/Test: WF 8.1.5 on (Windows Server 2012 R2 ) SandBox: WebFocus Server 8.1.5 on Windows Server 2008 R2 WebFOCUS App Studio 8.1.5 and Developer Studio 8.1.5 on Windows 7
Posts: 134 | Location: USA | Registered: August 21, 2008
i THINK THIS FEATURE IS NOT AVAILABLE IN 8.1.5m WHICH WE HAVE
Prod/Dev/Test: WF 8.1.5 on (Windows Server 2012 R2 ) SandBox: WebFocus Server 8.1.5 on Windows Server 2008 R2 WebFOCUS App Studio 8.1.5 and Developer Studio 8.1.5 on Windows 7
Posts: 134 | Location: USA | Registered: August 21, 2008
If you don't have a need to partition by a BY field then you can set up a simple counter using LAST (you can then hide the counter with a NOPRINT). Then using IF...THEN logic you can bring down the values of the first line.
TABLE FILE GGSALES
PRINT
COMPUTE COUNTER/I4 = LAST COUNTER + 1; NOPRINT
COMPUTE flda/A4 = EDIT(COUNTER);
COMPUTE fldb/I11 = IF COUNTER EQ 1 THEN DOLLARS ELSE LAST fldb;
BY PCD NOPRINT
ON TABLE SET PAGE-NUM OFF
ON TABLE SET BYDISPLAY ON
ON TABLE SET STYLE *
TYPE=REPORT, LINES-PER-PAGE=UNLIMITED, $
END
If you want to break it up between BY fields you can do that as well using LAST
TABLE FILE GGSALES
PRINT
COMPUTE PARTITION_NUM/I4 = IF PCD NE LAST PCD THEN PARTITION_NUM + 1 ELSE PARTITION_NUM;
COMPUTE PARTITION_ROW/I4 = IF PCD NE LAST PCD THEN 1 ELSE LAST PARTITION_ROW + 1;
COMPUTE FIRST_DOLLARS/I11 = IF PARTITION_ROW EQ 1 THEN DOLLARS ELSE LAST FIRST_DOLLARS;
COMPUTE RUNNING_TOTAL/I11 = IF PARTITION_ROW EQ 1 THEN DOLLARS ELSE LAST RUNNING_TOTAL + DOLLARS ;
BY PCD
ON TABLE SET PAGE-NUM OFF
ON TABLE SET BYDISPLAY ON
ON TABLE SET STYLE *
TYPE=REPORT, LINES-PER-PAGE=UNLIMITED, $
END
This message has been edited. Last edited by: Hallway,
Hallway
Prod: 8202M1
Test: 8202M4
Repository:
OS:
Outputs:
Posts: 608 | Location: Salt Lake City, UT, USA | Registered: November 18, 2015