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     [SOLVED]concatenating an apostrophe to a string
Go
New
Search
Notify
Tools
Reply
  
[SOLVED]concatenating an apostrophe to a string
 Login/Join
 
Platinum Member
posted
I can't get the synatax right for adding an apostrophe in front of a string. I've tried the two scenarios below but get the same results for both

 
-SET &GRAD = 'COMPUTE GRAD/A6 = IF J7.SEG01.gradtermint NE MISSING THEN '|''|'gradtermint ELSE '|''|'EDIT(DEANHLD.SEG01.gradint);';


PRINT
     &GRAD
     COMPUTE GRAD2/A6 = IF J7.SEG01.gradtermint NE MISSING THEN ''|gradtermint ELSE ''|EDIT(DEANHLD.SEG01.gradint);
 


The results for both GRAD and GRAD2 are
19

when I want
'19

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


WF8
Windows
 
Posts: 110 | Registered: May 28, 2015Reply With QuoteReport This Post
Platinum Member
posted Hide Post
Does this help?

-*
-SET &VAR1 = '19';
-SET &VAR2 = '''' | &VAR1;
-*
-TYPE VAR1 ------ &VAR1
-TYPE VAR2 ------ &VAR2
-EXIT


WebFocus 8.201M, Windows, App Studio
 
Posts: 221 | Location: Lincoln Nebraska | Registered: August 12, 2008Reply With QuoteReport This Post
Platinum Member
posted Hide Post
That doesn't actually display the ' before the number. I still am displaying only 19 not '19. I've tried outputing this to HTML and XLSX


WF8
Windows
 
Posts: 110 | Registered: May 28, 2015Reply With QuoteReport This Post
Platinum Member
posted Hide Post
What about this?

TABLE FILE CAR
PRINT
CAR
COMPUTE CAR1/A20 = '''' | CAR;
BY COUNTRY
END


WebFocus 8.201M, Windows, App Studio
 
Posts: 221 | Location: Lincoln Nebraska | Registered: August 12, 2008Reply With QuoteReport This Post
Platinum Member
posted Hide Post
My first example gives me this ...

VAR1 ------ 19
VAR2 ------ '19

Did you not get that?


WebFocus 8.201M, Windows, App Studio
 
Posts: 221 | Location: Lincoln Nebraska | Registered: August 12, 2008Reply With QuoteReport This Post
Platinum Member
posted Hide Post
The COMPUTE worked but the SET did not.

Thanks!


WF8
Windows
 
Posts: 110 | Registered: May 28, 2015Reply With QuoteReport This Post
  Powered by Social Strata  
 

Focal Point    Focal Point Forums  Hop To Forum Categories  WebFOCUS/FOCUS Forum on Focal Point     [SOLVED]concatenating an apostrophe to a string

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