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     [COLSED]Conditional Row?

Read-Only Read-Only Topic
Go
Search
Notify
Tools
[COLSED]Conditional Row?
 Login/Join
 
Platinum Member
posted
I am trying to add a row to a table when it meets a certain criteria. When one of the current rows has a numerical value for the field "national brand" I would like a row to follow showing that ITEMs information.

Currently I made a report that only shows off brand items, Its designed to show to our customers. I would like to contain information about the national brand, if that generic ITEM has a "national brand" if it does i would like it to spit out the information about the national brand right below the information about the generic brand.

If the generic brand doesn't have a national brand its just 00000

If it does i would like to make another row filled out with the National Brand Information


EX.

________________________________(invisable col)
catalogcode____ITEMCODE___Size___NATIONAL_Brand___ Price
00001__________12345______5______00000____________1.00
......................................................
00002__________12346______8______00000____________2.00
......................................................
00003__________12347______4______00000____________1.50
......................................................
00004__________12348______5______47532____________2.50
39642__________47532______5______N/A______________3.50
......................................................
00005__________12349______3______00000____________2.00
......................................................
00006__________12350______1______37634____________3.00
34254__________37634______1______N/A______________4.00


Does Anyone know how to do conditional Rows? Or how I would be able to do this??

This message has been edited. Last edited by: Charles Richards,


WebFOCUS 7.6
Windows, All Outputs
 
Posts: 111 | Registered: May 12, 2011Report This Post
Virtuoso
posted Hide Post
You might be able to use SUBFOOT with a WHEN clause. For example:

TABLE FILE ...
 PRINT/SUM ....
 BY catalogcode
 BY ITEMCODE
 BY NATIONAL_Brand NOPRINT
 ON NATIONAL_Brand SUBFOOT
  "<field1<field2<etc..."
  WHEN NATIONAL_Brand NE '00000' ;
 ON TABLE STYLE *
  TYPE=SUBFOOT, HEADALIGN=BODY, $
END


WebFOCUS 7.7.05
 
Posts: 1213 | Location: Seattle, Washington - USA | Registered: October 22, 2007Report This Post
Platinum Member
posted Hide Post
It worked and it was able to spit out data at the correct spot(up and down but not lined up with the other columns)...

I did

BY catalogcode
BY ITEMCODE
ON ITEMCODE SUBFOOT



How would I be able to retreieve the data for national brand? / Set the ITEMCODE = to the National brand( in the SUBFOOT)?



ALSO, How Can I line them up with the other columns?

This message has been edited. Last edited by: Charles Richards,


WebFOCUS 7.6
Windows, All Outputs
 
Posts: 111 | Registered: May 12, 2011Report This Post
Virtuoso
posted Hide Post
Add a DEFINE or COMPUTE to set ITEMCODE = NATIONAL_Brand for the SUBFOOT. The StyleSheet parameter HEADLIGN=BODY is used to align SUBFOOT columns with the data columns.

DEFINE FILE ...
 ITEMCODE_SF/A5 = IF (NATIONAL_Brand NE '00000') THEN NATIONAL_Brand ELSE ITEMCODE ;
END
-*
TABLE FILE ...
 PRINT/SUM ....
 BY catalogcode
 BY ITEMCODE
 BY NATIONAL_Brand NOPRINT
 ON NATIONAL_Brand SUBFOOT
  "<catalogcode<ITEMCODE_SF<Size<NATIONAL_Brand<Price"
  WHEN NATIONAL_Brand NE '00000' ;
 ON TABLE STYLE *
  TYPE=SUBFOOT, HEADALIGN=BODY, $
END

This message has been edited. Last edited by: Dan Satchell,


WebFOCUS 7.7.05
 
Posts: 1213 | Location: Seattle, Washington - USA | Registered: October 22, 2007Report This Post
Platinum Member
posted Hide Post
Thank you so Much for you help!

I have one last question

How would i retrieve the catalog code and other values where the ITEMCODE = the national brand


currently it is retrieveing the value of the current ITEMCODE, I would like it to retrieve all of the values using national brand as the itemcode, How would i be able to accomplish this?

Thank you very much for all of your help!!


WebFOCUS 7.6
Windows, All Outputs
 
Posts: 111 | Registered: May 12, 2011Report This Post
Virtuoso
posted Hide Post
Adding more DEFINEs or COMPUTEs may solve the problem, but it is impossible to know exactly what solution will work without knowing more about the structure of your data. Are the "local" and national brand data in the same table or HOLD file? If both are in the same table/HOLD file, are related local and national brand items sorted one after the other? If the two types of data are in different tables, how are the two tables joined or merged?


WebFOCUS 7.7.05
 
Posts: 1213 | Location: Seattle, Washington - USA | Registered: October 22, 2007Report 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     [COLSED]Conditional Row?

Copyright © 1996-2020 Information Builders