Portal | Manuals | References | Downloads | Info | Programs | JCLs | Master the Mainframes
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Usergroups Profile Log in to check your private messages Log in
 

 

Write the contents of a variable to a PS file

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> CLIST & REXX
View previous topic :: :: View next topic  
Author Message
PrabakarV

New User


Joined: 21 Dec 2007
Posts: 88
Location: My Desk

PostPosted: Tue Oct 06, 2009 6:19 pm    Post subject: Write the contents of a variable to a PS file
Reply with quote

Hi,

I have a variable like this below....

Code:
var1 = " hi this is query1 ",
           " this is query2",
           " this is query 3 too"


i need to write it to a ps file. i can able to write it line by line by pushing... if i want to write var1 in single execio write what is the command.... other than execio is there anyway?

can anyone help me... Thanks...
Back to top
View user's profile Send private message

Pedro

Senior Member


Joined: 01 Sep 2006
Posts: 2025
Location: Silicon Valley

PostPosted: Tue Oct 06, 2009 7:36 pm    Post subject: Reply to: Write the contents of a variable to a PS file
Reply with quote

What have you tried?

You should be able to concatenate the long string as in your example, then
Code:
PUSH var1
Back to top
View user's profile Send private message
expat

Global Moderator


Joined: 14 Mar 2007
Posts: 8593
Location: Back in jolly old England

PostPosted: Tue Oct 06, 2009 7:43 pm    Post subject:
Reply with quote

Not really sure what you are asking here.

With the continuation comma at the end of each line, VAR1 is one variable which contains the whole of the text that you have put across three lines.
Back to top
View user's profile Send private message
PrabakarV

New User


Joined: 21 Dec 2007
Posts: 88
Location: My Desk

PostPosted: Wed Oct 07, 2009 10:07 am    Post subject:
Reply with quote

Thanks Pedro & Expat...

I have tried push command earlier... my ps file file lrecl is 80... after push the write does the one line wirting only... so that i am getting a bit of it...

now i under stand as Expat said it is a one line so i need to break it into pieces....

is there any way i can write them line by line as displayed above in my code...

simply sayin i need them in ps as it is code above (three lines )... is possible thru rexx... since i am new to rexx i need to learn a lot... Thanks...
Back to top
View user's profile Send private message
dick scherrer

Site Director


Joined: 23 Nov 2006
Posts: 19270
Location: Inside the Matrix

PostPosted: Wed Oct 07, 2009 7:35 pm    Post subject:
Reply with quote

Hello,

Instead of using only var1 for the "whole string", use var1, var2, and var3. . .
Back to top
View user's profile Send private message
PrabakarV

New User


Joined: 21 Dec 2007
Posts: 88
Location: My Desk

PostPosted: Thu Oct 08, 2009 5:03 pm    Post subject:
Reply with quote

Thanks Dick.... while starting to do it, i tried with that option only and it worked... i am just trying out in different ways...
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> CLIST & REXX All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts SORTJOIN - Copy Matched and Unmatched... Steve Ironmonger DFSORT/ICETOOL 5 Tue Jan 17, 2017 4:26 pm
No new posts Copy RECFM =VB TO FB file with RECL =... sahil41352 DFSORT/ICETOOL 3 Wed Dec 28, 2016 11:29 pm
No new posts Add PD field from 2nd file to PD in 1st Sushant Garje DFSORT/ICETOOL 6 Thu Dec 01, 2016 4:32 pm
No new posts File Aid to File Manager conversion murali3955 IBM Tools 4 Thu Nov 24, 2016 3:41 pm
No new posts How to convert the VBM file to VB or... Sulabh Agrawal JCL & VSAM 4 Fri Nov 18, 2016 1:04 pm


Facebook
Back to Top
 
Mainframe Wiki | Forum Rules | Bookmarks | Subscriptions | FAQ | Tutorials | Contact Us