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] dynamic column names

Read-Only Read-Only Topic
Go
Search
Notify
Tools
[SOLVED] dynamic column names
 Login/Join
 
<Sathish.B>
posted
When I run the below code I get only SEATS as column names, any idea how to get the CAR names in the column title

TABLE FILE CAR
SUM SEATS
BY COUNTRY
ACROSS CAR
ON TABLE HOLD AS TEMP
END
-RUN

TABLE FILE TEMP
PRINT *
END

This message has been edited. Last edited by: Kathleen Butler,
 
Report This Post
Expert
posted Hide Post
If you are going to hold your data prior to printing it out then there is no reason to use an across phrase - just use BY.

Once you have the held data, then report on it using the ACROSS phrase -
TABLE FILE CAR
SUM SEATS
BY COUNTRY
BY CAR
ON TABLE HOLD AS TEMPFILE
END
-RUN

TABLE FILE TEMPFILE
SUM SEATS
BY COUNTRY
ACROSS CAR
END


I take it that this is just an example of a much larger process as there is little point in holding the first extract to then report upon it, you might as well do it in one pass!

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
<Sathish.B>
posted
Tony, i wanted an output in this format.

COUNTRY BMW BENZ AUDI
ENGLAND . 8 .
ITALY 9 . .
JAPAN 6 9 .

so that i can refer BMW, BENZ, AUDI as separate columns for further processing. Not sure if this is possible.
 
Report This Post
Expert
posted Hide Post
Sathish..
just don't hold the interim file, as T says.
the creation of special across names
'seaengland' 'seafrance' etc, is a very useful feature of webfocus, concatenating the first three letters of the measurename and the across field value. This will be very useful, as your programming talents grow.
If you must hold and retable, then
SET ASNAMES = ON
TABLE FILE CAR
SUM SEATS AS '' BY COUNTRY ACROSS CAR
ON TABLE HOLD
END
TABLE FILE HOLD PRINT *
END

This message has been edited. Last edited by: susannah,




In Focus since 1979///7706m/5 ;wintel 2008/64;OAM security; Oracle db, ///MRE/BID
 
Posts: 3811 | Location: Manhattan | Registered: October 28, 2003Report This Post
<Sathish.B>
posted
Thanks a ton, this was the output i was looking for. will help me lot in my project.
 
Report This Post
Guru
posted Hide Post
quote:
SET ASNAMES = ON
TABLE FILE CAR
SUM SEATS AS '' BY COUNTRY ACROSS CAR
ON TABLE HOLD
END
TABLE FILE HOLD PRINT *
END



Sorry for opening this way old thread...

But if I am making this as

 ON TABLE HOLD AS HLD1 FORMAT FOCUS 


Then the column names are not retained... Any SET commands to have that?


Thanks,

Ramkumar.
WebFOCUS/Tableau
Webfocus 8 / 7.7.02
Unix, Windows
HTML/PDF/EXCEL/AHTML/XML/HTML5
 
Posts: 394 | Location: Chennai | Registered: December 02, 2009Report This Post
Guru
posted Hide Post
The thing is TITLE='', $ is how it is setting up in the master file it is creating for the focus mart.

Having an intermediate HOLD file resolved the issue.

This message has been edited. Last edited by: Ramkumar - Webfous,


Thanks,

Ramkumar.
WebFOCUS/Tableau
Webfocus 8 / 7.7.02
Unix, Windows
HTML/PDF/EXCEL/AHTML/XML/HTML5
 
Posts: 394 | Location: Chennai | Registered: December 02, 2009Report 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] dynamic column names

Copyright © 1996-2020 Information Builders