Focal Point Banner
Community Center Education Summit Technical Support User Groups
Let's Get Social!

Facebook Twitter LinkedIn YouTube
Focal Point    Focal Point Forums  Hop To Forum Categories  WebFOCUS/FOCUS Forum on Focal Point     [CLOSED] Print multiple parameters that are selected table Column titles
Go
New
Search
Notify
Tools
Reply
  
[CLOSED] Print multiple parameters that are selected table Column titles
 Login/Join
 
Silver Member
posted
from this list (the parameters) Column titles of a table
I want to display only the columns selected as a multiple select

(in my HTML as a list)










Tried this works for only 1 option value at a time i.e. 1 Column only as output (no good)

&Opt_SQL = '&Opt_SQL'
-SET &TEXT2 = STRREP(&Opt_SQL.LENGTH,&Opt_SQL,4,' or ',1,',',&Opt_SQL.LENGTH,'&Opt_SQL');
-SET &TEXT3 = STRIP(&TEXT2.LENGTH,&TEXT2,'''','&TEXT2');
SQL SQLMSS PREPARE SQLOUT FOR
SELECT
&TEXT3
FROM dbo.ServiceApplication
;
END
TABLE FILE SQLOUT
PRINT
*
ON TABLE NOTOTAL
ON TABLE PCHOLD FORMAT HTML
ON TABLE SET HTMLCSS ON
END


when I try 2 or more option values I get an error

This message has been edited. Last edited by: Kerry,


WebFOCUS 7.6
Windows, All Outputs
 
Posts: 37 | Registered: December 03, 2010Reply With QuoteReport This Post
Expert
posted Hide Post
What does &TEXT3 contain when multiple are selected ?


Waz...

Prod:WebFOCUS 7.6.10/8.1.04Upgrade:WebFOCUS 8.2.06OS:LinuxOutputs:HTML, PDF, Excel, PPT
In Focus since 1984
Pity the lost knowledge of an old programmer!

 
Posts: 6275 | Location: 33°49'23.0"S, 151°11'41.0"E | Registered: October 31, 2006Reply With QuoteReport This Post
Silver Member
posted Hide Post
the error is

(FOC1517) UNRECOGNIZED COMMAND ''BUSINESSSPONSOR'' OR ''CERTSTATUS'' =
'''BUSINESSSPONSOR'' OR ''CERTSTATUS'''
(FOC1400) SQLCODE IS 156 (HEX: 0000009C) XOPEN: 42000
: Microsoft SQL Native Client: [42000] Incorrect syntax near the keyword 'OR'. [42000] Statement(s) could not be prepared. [] Deferred prepare could not be completed.
L (FOC1405) SQL PREPARE ERROR.
(FOC205) THE DESCRIPTION CANNOT BE FOUND FOR FILE NAMED: SQLOUT
BYPASSING TO END OF COMMAND

However the removal of the ' or ' was I believe successful


WebFOCUS 7.6
Windows, All Outputs
 
Posts: 37 | Registered: December 03, 2010Reply With QuoteReport This Post
Silver Member
posted Hide Post
WAS

-? & informed me that it did not have the results required


WebFOCUS 7.6
Windows, All Outputs
 
Posts: 37 | Registered: December 03, 2010Reply With QuoteReport This Post
Silver Member
posted Hide Post
Upper Case ' OR ' and it works now in the line
-SET &TEXT2 = STRREP(&Opt_SQL.LENGTH,&Opt_SQL,4,' or ',1,',',&Opt_SQL.LENGTH,'&Opt_SQL');


WebFOCUS 7.6
Windows, All Outputs
 
Posts: 37 | Registered: December 03, 2010Reply With QuoteReport This Post
Expert
posted Hide Post
Add -SET &ECHO=ALL; before the -SET &TEXT2

And add -TYPE &TEXT3 after -SET &TEXT3.


Waz...

Prod:WebFOCUS 7.6.10/8.1.04Upgrade:WebFOCUS 8.2.06OS:LinuxOutputs:HTML, PDF, Excel, PPT
In Focus since 1984
Pity the lost knowledge of an old programmer!

 
Posts: 6275 | Location: 33°49'23.0"S, 151°11'41.0"E | Registered: October 31, 2006Reply With QuoteReport This Post
Silver Member
posted Hide Post
Waz
Thank you, I forget that WEB FOCUS is Case Sensitive… I guess I’m just a case insensitive kind of guy.


WebFOCUS 7.6
Windows, All Outputs
 
Posts: 37 | Registered: December 03, 2010Reply With QuoteReport This Post
Expert
posted Hide Post
I certainly didn't spot the case difference, I suspect that I'm insensitive too, certainly been called it a lot.

Smiler


Did the case change help ?


Waz...

Prod:WebFOCUS 7.6.10/8.1.04Upgrade:WebFOCUS 8.2.06OS:LinuxOutputs:HTML, PDF, Excel, PPT
In Focus since 1984
Pity the lost knowledge of an old programmer!

 
Posts: 6275 | Location: 33°49'23.0"S, 151°11'41.0"E | Registered: October 31, 2006Reply With QuoteReport This Post
Silver Member
posted Hide Post
Waz

Yes the Case sensitivity and its observation has made the query work... so the next step is an eloquent (simple) code to display what is selected from the HTML options List (left side of page) into a GUI display list (right side) so the user can onclick copy the selection to the display list where a confirmation of items can occur...then the query runs with the selected parameters


WebFOCUS 7.6
Windows, All Outputs
 
Posts: 37 | Registered: December 03, 2010Reply With QuoteReport This Post
Expert
posted Hide Post
Good luck,

If you need help, we are only a post away. Smiler


Waz...

Prod:WebFOCUS 7.6.10/8.1.04Upgrade:WebFOCUS 8.2.06OS:LinuxOutputs:HTML, PDF, Excel, PPT
In Focus since 1984
Pity the lost knowledge of an old programmer!

 
Posts: 6275 | Location: 33°49'23.0"S, 151°11'41.0"E | Registered: October 31, 2006Reply With QuoteReport This Post
  Powered by Social Strata  
 

Focal Point    Focal Point Forums  Hop To Forum Categories  WebFOCUS/FOCUS Forum on Focal Point     [CLOSED] Print multiple parameters that are selected table Column titles

Copyright © 1996-2018 Information Builders, leaders in enterprise business intelligence.