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     Another question for previous problem

Read-Only Read-Only Topic
Go
Search
Notify
Tools
Another question for previous problem
 Login/Join
 
Member
posted
The data I'm using to do a counter on is very large. What I'm guessing I need to do is create a hold file with just the records I need to run the report on then do a counter on the hold file?? Can that be done? Thanks in advance, been a while since I went to training and there's no one here that knows. : (
 
Posts: 8 | Registered: May 20, 2006Report This Post
Expert
posted Hide Post
without knowing what your previous problem was, actually, the answer to this questions is yes indeed.
TABLE FILE CAR
SUM somethings
IF someconditions
ON TABLE HOLD
END
TABLE FILE HOLD
COUNT something
...
END




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
Member
posted Hide Post
Thanks for the speedy responce
 
Posts: 8 | Registered: May 20, 2006Report This Post
Platinum Member
posted Hide Post
Mchll,

Does this not work for you?

TABLE FILE CAR
COUNT something
IF someconditions
END

I can't imagine why not, unless you're getting asterisks in the count field. If that's all that's going on, change the count command to:

COUNT something/I9C

If something else is going on, I'd be curious what it is.


dwf
 
Posts: 135 | Location: Portland, OR | Registered: March 23, 2005Report This Post
Member
posted Hide Post
The hold file worked.
My previous question was: "I have some data that has equipment for accounts, about 12,000 records. Most of the accounts have more than one piece of equipment and I need to sum the data so that there's one account with each different type of equipment concatinated into one column. My thought is to index and run the data through a loop to concatinate the equipment types."

Here's what I I have so far:
APP PATH 1STAR

DEFINE FILE TASQ_DAILY_SHIPPING
SDATE/YYMD = HDATE(SHIP_DATE,'YYMD') ;
XSDATE/MDY = SDATE ;
END

TABLE FILE TASQ_DAILY_SHIPPING
SUM
XSDATE
PART_ID
BY
MERCHANT_NUMBER
IF XSDATE GE '05/15/2006'
ON TABLE HOLD
END

DEFINE FILE HOLD
CNTR/I1=IF MERCHANT_NUMBER EQ LAST MERCHANT_NUMBER AND PART_ID NE LAST PART_ID THEN CNTR + 1
ELSE 1;
END
TABLE FILE HOLD
WRITE PART_ID
ACROSS CNTR NOPRINT BY MERCHANT_NUMBER
END

This worked ok but it did not concatinate the part id's.
 
Posts: 8 | Registered: May 20, 2006Report This Post
Platinum Member
posted Hide Post
I can't quite tell from your response whether you have a partial or complete solution. Your respne started with 'The hold file worked' and ended with 'This worked ok but it did not concatenae the part id's'. Can't tell if that last statement is from your latest post or the previous post to which you alluded. If you don't post anything else, I will assume you have a complete solution.


dwf
 
Posts: 135 | Location: Portland, OR | Registered: March 23, 2005Report This Post
Member
posted Hide Post
I'm not the best communicator, sorry. My problem is not really solved. I have not been able to get the one merchant number with all part ids in one column. I no longer have multiple rows per merchant but I have no idea what happened to the other part id's. No worries.
 
Posts: 8 | Registered: May 20, 2006Report This Post
Platinum Member
posted Hide Post
What happened is that you summed part id by merchant. I assume part id is alhpanumeric, in which case focus grabbed the last one for each merchant, and ignored the rest.

I may be off the track here, but the code below might get you started in the right direction (without a hold). It assumes merchant number is numeric and part id is alpha. If they are both alpha, then you don't need MERCHNUM. This ought to give you all parts, though you'll see one line per merchant/part.

Are you looking for something different?

APP PATH 1STAR

DEFINE FILE TASQ_DAILY_SHIPPING
SDATE/YYMD = HDATE(SHIP_DATE,'YYMD') ;
XSDATE/MDY = SDATE ;
MERCHNUM/A10 = EDIT(MERCHANT_NUMBER);
MERCH_PART/A21 = MERCHNUM | ' ' | PART_ID;
END

TABLE FILE TASQ_DAILY_SHIPPING
SUM
XSDATE
COMPUTE
CNTR/I9C=IF MERCHANT_NUMBER EQ LAST MERCHANT_NUMBER THEN CNTR + 1 ELSE 1;
BY MERCH_PART AS 'Merchant - Part'
IF XSDATE GE '05/15/2006'
END


dwf
 
Posts: 135 | Location: Portland, OR | Registered: March 23, 2005Report This Post
Member
posted Hide Post
I'll give it a try tomorrow. Thanks for helping, I do appreciate it. Have a good night.
 
Posts: 8 | Registered: May 20, 2006Report This Post
Platinum Member
posted Hide Post
I have thought some about my last reply. I don't think it will give you quite what you want. I wonder if this will solve your problem in a different way:

APP PATH 1STAR

DEFINE FILE TASQ_DAILY_SHIPPING
SDATE/YYMD = HDATE(SHIP_DATE,'YYMD') ;
XSDATE/MDY = SDATE ;
END

TABLE FILE TASQ_DAILY_SHIPPING
COUNT
PART_ID
BY MERCHANT_NUMBER
PRINT
XSDATE
BY MERCHANT_NUMBER
BY PART_ID
IF XSDATE GE '05/15/2006'
END

This is a very different animal. But if you want to see a cout of parts by merchant, and you want the parts listed, this might be what you are looking for.


dwf
 
Posts: 135 | Location: Portland, OR | Registered: March 23, 2005Report This Post
Member
posted Hide Post
I haven't had a chance to try yet, I will soon. Thanks again for helping out!
 
Posts: 8 | Registered: May 20, 2006Report 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     Another question for previous problem

Copyright © 1996-2020 Information Builders