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     Problem with Recompute

Read-Only Read-Only Topic
Go
Search
Notify
Tools
Problem with Recompute
 Login/Join
 
Platinum Member
posted
Hi all, if I have a statement as follows
 <br />COMPUTE NJUNO/P9CN=IF JUNO LE 0  THEN 0 ELSE JUNO;AS '&M3,Open' 
and my values for JUNO are

-1000
500
200
so when I run my report I get
0
500
200

but now on my recompute line I also get 0, I guess that is becuase The sum of the actual values is less than 0, but how do I make it only look at the COMPUTED VALUES so that I would get 700?
 
Posts: 157 | Location: Secaucus, NJ | Registered: May 21, 2004Report This Post
Silver Member
posted Hide Post
Lloyd,

If I understand correct this is what you are trying to do. I have used the DEALER_COST - 10000 to create negative values. Compute can be used like define as in the following code.

COMPUTE FILE CAR
DCOST/I8 = DEALER_COST - 10000;
TEMP/P9CN = IF DCOST LE 0 THEN 0 ELSE DCOST;
END
TABLE FILE CAR
PRINT
CAR
DCOST
TEMP
ON TABLE RECOMPUTE AS 'Total'
END

Hope this helps

M
 
Posts: 33 | Location: New York, USA | Registered: August 11, 2003Report This Post
Platinum Member
posted Hide Post
Since you are only displaying positive values why do you need the RECOMPUTE at all? A simple Column-total will give you 700 in your example.
 
Posts: 226 | Registered: June 08, 2003Report This Post
Expert
posted Hide Post
Lloyd,
can you possibly use a define
NJUNO/P9=MAX(0,JUNO);
or
can you possibly do
COMPUTE NJUNO/P9=MAX(0,JUNO);NOPRINT
COMPUTE NJUNO1/P9=NJUNO; AS 'nicelabel'
 
Posts: 3811 | Location: Manhattan | Registered: October 28, 2003Report This Post
Platinum Member
posted Hide Post
Actually I was doing it the way Mickey shows( which his example does work), but for some reason I kept getting zero as the total. My assumption was, that because the sum of the actual values is less than zero, that it displayed the zero. I'll have to do some more testing with the actual data to see why I was getting the zero
 
Posts: 157 | Location: Secaucus, NJ | Registered: May 21, 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     Problem with Recompute

Copyright © 1996-2020 Information Builders