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.



Read-Only Read-Only Topic
Go
Search
Notify
Tools
Eliminate records
 Login/Join
 
Platinum Member
posted
Hello

I have a dataset

FIELD1      FIELD2
A1          K1 
A2          K1
A3          K1
A1          K2
A2          K2
A3          K2 
A1          K3
A1          K4
A2          K4
A3          K4


I am trying to eliminate record with K3 as it has only 1 record associated with A1 but not with A2 and A3. I tried using LAST but 1st records of each value in FIELD2 is getting eliminated. Any thoughts?

Thank you...


WF 8.2.01 APP STUDIO
PDF,HTML,EXL2K,Active
 
Posts: 139 | Registered: July 21, 2011Report This Post
Virtuoso
posted Hide Post
"Eliminate" means deleted from your database, or not displayed on your report?

If you want to simply not show singletons (in Field 2) on your report you could use WHERE TOTAL logic.

TABLE FILE X
SUM CNT.FIELD2 NOPRINT
BY FIELD1 NOPRINT
PRINT FIELD1
FIELD2
WHERE TOTAL CNT.FIELD2 GT 1
END

I'm just winging it without running through a compiler, but that's more or less the gist of it. I'm not sure you even need the SUM part at the beginning, but I wanted to show you the bigger picture in case it is required.

J.



 
Posts: 1012 | Location: At the Mast | Registered: May 17, 2007Report This Post
Platinum Member
posted Hide Post
Actually I must change my question. I use similar logic as of now.

But lets say record should be eliminated even if K3 has any other value other than A2 and A3.

this logic would not apply for this scenario.
i am trying to get this to work..
quote:
Originally posted by John_Edwards:
"Eliminate" means deleted from your database, or not displayed on your report?

If you want to simply not show singletons (in Field 2) on your report you could use WHERE TOTAL logic.

TABLE FILE X
SUM CNT.FIELD2 NOPRINT
BY FIELD1 NOPRINT
PRINT FIELD1
FIELD2
WHERE TOTAL CNT.FIELD2 GT 1
END

I'm just winging it without running through a compiler, but that's more or less the gist of it. I'm not sure you even need the SUM part at the beginning, but I wanted to show you the bigger picture in case it is required.

J.


WF 8.2.01 APP STUDIO
PDF,HTML,EXL2K,Active
 
Posts: 139 | Registered: July 21, 2011Report This Post
Virtuoso
posted Hide Post
I'll need a clearer understanding of your requirements in order to help more, BD. I don't mind helping if you want to take the time to write them up more comprehensively.

J.



 
Posts: 1012 | Location: At the Mast | Registered: May 17, 2007Report This Post
Virtuoso
posted Hide Post
BI,

Do you mean that FIELD2 is a singleton AND FIELD1 is not A2 or A3?


Daniel
In Focus since 1982
wf 8.202M/Win10/IIS/SSA - WrapApp Front End for WF

 
Posts: 1980 | Location: Tel Aviv, Israel | Registered: March 23, 2006Report This Post
Master
posted Hide Post
How's this...

DEFINE FILE X
 BAD_VALUE_COUNTER/I1 = IF NOT ( FIELD1 EQ 'A1 OR 'A2' ) THEN 1 ELSE 0;
END

TABLE FILE X
SUM
   BAD_VALUE_COUNTER NOPRINT
BY   FIELD1
BY   FIELD2
WHERE TOTAL BAD_VALUE_COUNTER EQ 0
END


Greets,
Dave


_____________________
WF: 8.0.0.9 > going 8.2.0.5
 
Posts: 668 | Location: Veghel, The Netherlands | Registered: February 16, 2010Report This Post
Virtuoso
posted Hide Post
Almost.
DEFINE FILE X
 HITS2/I1 = FIELD1 EQ 'A2';
 HITS3/I1 = FIELD1 EQ 'A3';
END
TABLE FILE X
 SUM
  HITS2 NOPRINT
  HITS3 NOPRINT
  BY WHATEVER
 PRINT
  FIELD1
  FIELD2
  BY WHATEVER
 WHERE TOTAL HITS2 + HITS3 GT 0;
END


- Jack Gross
WF through 8.1.05
 
Posts: 1925 | Location: NYC | In FOCUS since 1983 | Registered: January 11, 2005Report This Post
  Powered by Social Strata  

Read-Only Read-Only Topic


Copyright © 1996-2020 Information Builders