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.
Or have the « Multiple: Add Quotes » option of the control set to yes will add the enclosed single quote and no need to convert the comma to « quote-comma-quote ».
WF versions : Prod 8.2.04M gen 33, Dev 8.2.04M gen 33, OS : Windows, DB : MSSQL, Outputs : HTML, Excel, PDF In Focus since 2007
Posts: 2409 | Location: Montreal Area, Qc, CA | Registered: September 25, 2013
Thanks Martin and Ram for the solution but unfortunately I think I did not put my question in the right way.
Say if in the below query,the column named board is getting the values such as first last(single value) from the database(table) and in the html page,the static value for &board are first(1st static value) and the next value is last....Please let me know how to check for first last i.e.,board value in the table with that of &board i.e,the values being are first and the next value is being last...Iam not sure which operator to use i.e, Contains,IN,etc... select * from table WHERE number IN ('&id') AND name IN ('&name'); AND board IN (&board); END
Thanks Darryl ! Say the value for the board column which Iam getting from the table/database is abcd xyz which is a single value and the value which Iam passing for &board[static values] is abcd from the html page. Please let me know how to check for board value with the &board value in the filter condition in the query used above....
Iam using IN operator and also used LIKE operator but nothing seem to be working... Hope Iam clear now.
Sorry,that semicolon was present there by mistake. Here is the query : select * from table WHERE number IN ('&id') AND name IN ('&name') AND board IN (&board); END
You are looking for &board selected value anywhere in < board > field ? If you use the Focus TABLE FILE code, you won't have to worry about wild card characters. So having this (if we understand your request ), should work:
TABLE FILE ABC
PRINT *
WHERE number EQ &id;
WHERE name EQ '&name';
WHERE board CONTAINS '&board';
END
WF versions : Prod 8.2.04M gen 33, Dev 8.2.04M gen 33, OS : Windows, DB : MSSQL, Outputs : HTML, Excel, PDF In Focus since 2007
Posts: 2409 | Location: Montreal Area, Qc, CA | Registered: September 25, 2013
I considered suggesting that but have always assumed that a CONTAINS would have worse performance than a LIKE when you know the data you have is at the start of the string. Do you happen to know if my assumption is true or if I have made it up!
Many thanks
(and being an old SQL programmer I hadn't even noticed the 'select *' and was thinking 'table file' - so good point there)
7.7.05 Windows.
Posts: 39 | Location: UK | Registered: July 11, 2012
Hi Darryl, It's true that a CONTAINS will try to find the character set (parameter value) anywhere in the search string (field), so may become a lack of performance. But if the searched string is at the beginning of the field, it will do the same thing as LIKE 'abc%'. The advantage of CONTAINS is that you're not limited to search at the beginning of the string without having to change your condition.
WF versions : Prod 8.2.04M gen 33, Dev 8.2.04M gen 33, OS : Windows, DB : MSSQL, Outputs : HTML, Excel, PDF In Focus since 2007
Posts: 2409 | Location: Montreal Area, Qc, CA | Registered: September 25, 2013
Thanks everyone for the solution. But Iam passing multiple values of &board from the html page and I will also be passing the value ALL(i.e.,FOC_NONE) and Iam not sure whether the operator CONTAINS works or not.