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] Changing an OR separated value

Read-Only Read-Only Topic
Go
Search
Notify
Tools
[SOLVED] Changing an OR separated value
 Login/Join
 
Gold member
posted
Hi all,
I've been working on an HTML page that uses checkboxes. The way the checkbox string is produced, it is equal to something like
'X' OR 'Y' OR 'Z'
But the quotes around each individual value are creating a bit of a problem. I have found that if I manually enter it, it will work if the outputted string is formatted in one of two ways.
'X OR Y OR Z', or
X,Y,Z
How would I change the way the string is formatted to be either of those?

This message has been edited. Last edited by: FP Mod Chuck,


WebFOCUS 8.2.01M on Windows 10
 
Posts: 54 | Registered: July 30, 2018Report This Post
Platinum Member
posted Hide Post
One way ...

-*
-SET &IND_SECT  = '''X'' OR ''Y'' OR ''Z''';
-SET &IND_SECT1 = TRUNCATE(STRREP(&IND_SECT.LENGTH,&IND_SECT,6,''' OR ''',4,' OR ',&IND_SECT.LENGTH,A&IND_SECT.LENGTH));
-*
-TYPE IND_SECT -------------- &IND_SECT
-TYPE IND_SECT(LENGTH) ------ &IND_SECT.LENGTH
-TYPE -----------------------
-TYPE IND_SECT1 ------------- &IND_SECT1
-TYPE IND_SECT1(LENGTH) ----- &IND_SECT1.LENGTH


WebFocus 8.201M, Windows, App Studio
 
Posts: 227 | Location: Lincoln Nebraska | Registered: August 12, 2008Report This Post
Platinum Member
posted Hide Post
Or this gives you both ...

-*
-SET &IND_SECT  = '''X'' OR ''Y'' OR ''Z''';
-SET &IND_SECT1 = TRUNCATE(STRREP(&IND_SECT.LENGTH,&IND_SECT,4,' OR ',1,',',&IND_SECT.LENGTH,A&IND_SECT.LENGTH));
-SET &IND_SECT2 = TRUNCATE(STRREP(&IND_SECT1.LENGTH,&IND_SECT1,1,'''',0,'',&IND_SECT1.LENGTH,A&IND_SECT1.LENGTH));
-*
-TYPE IND_SECT -------------- &IND_SECT
-TYPE IND_SECT(LENGTH) ------ &IND_SECT.LENGTH
-TYPE -----------------------
-TYPE IND_SECT1 ------------- &IND_SECT1
-TYPE IND_SECT1(LENGTH) ----- &IND_SECT1.LENGTH
-TYPE -----------------------
-TYPE IND_SECT2 ------------- &IND_SECT2
-TYPE IND_SECT2(LENGTH) ----- &IND_SECT2.LENGTH


WebFocus 8.201M, Windows, App Studio
 
Posts: 227 | Location: Lincoln Nebraska | Registered: August 12, 2008Report This Post
Platinum Member
posted Hide Post
This gives you both using the REPLACE function ...

-SET &IND_SECT = '''X'' OR ''Y'' OR ''Z''';
-SET &IND_SECT1 = REPLACE(&IND_SECT, ''' OR ''', ' OR ');
-SET &IND_SECT2 = REPLACE(REPLACE(&IND_SECT, ' OR ', ',') ,'''', '');
-*
-TYPE IND_SECT -------------- &IND_SECT
-TYPE IND_SECT(LENGTH) ------ &IND_SECT.LENGTH
-TYPE -----------------------
-TYPE IND_SECT1 ------------- &IND_SECT1
-TYPE IND_SECT1(LENGTH) ----- &IND_SECT1.LENGTH
-TYPE -----------------------
-TYPE IND_SECT2 ------------- &IND_SECT2
-TYPE IND_SECT2(LENGTH) ----- &IND_SECT2.LENGTH


WebFocus 8.201M, Windows, App Studio
 
Posts: 227 | Location: Lincoln Nebraska | Registered: August 12, 2008Report This Post
Member
posted Hide Post
I believe you just need to go to the checkbox properties and set the "Multiple: Add quotes" setting to "No".


WebFOCUS 8.0.09
Windows 7
 
Posts: 3 | Location: San Antonio, TX | Registered: December 17, 2014Report 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] Changing an OR separated value

Copyright © 1996-2020 Information Builders