IBM Mainframe Forum Index
 
Log In
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Register
 

Use of Parm in SORT


IBM Mainframe Forums -> DFSORT/ICETOOL
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
Ambili S

Active User


Joined: 06 Sep 2007
Posts: 112
Location: India

PostPosted: Mon May 09, 2016 9:16 pm
Reply with quote

Hi

I am trying to get 'X' number of records from a file for each execution using ENDREC. I used SET and passed the value using PARM.

SET X=1000
In SORT , PARM='JP1"&X"'.

In Outfil i have ENDREC=JP1 , however, it is getting substituted as ENDREC=C'1000', instead of ENDREC=1000 and failing with syntax error.
Back to top
View user's profile Send private message
Rohit Umarjikar

Global Moderator


Joined: 21 Sep 2010
Posts: 2727
Location: NYC,USA

PostPosted: Mon May 09, 2016 10:34 pm
Reply with quote

Because that is a string. You would have to build a sort card which fits to your requirement and if you tell us more then someone can help you better.
Back to top
View user's profile Send private message
Bill Woodger

Moderator Emeritus


Joined: 09 Mar 2011
Posts: 7310
Location: Inside the Matrix

PostPosted: Tue May 10, 2016 3:51 am
Reply with quote

The JPn is a sort symbol. A symbol has a syntax. You can't necessarily use it anywhere you want. What release of DFSORT do you have?

If you want to do this "dynamically" with your DFSORT, have a separate step which generates the OUTFIL and use dataset concatenation on SYSIN to build the full sort cards on the second step.
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic View Bookmarks
All times are GMT + 6 Hours
Forum Index -> DFSORT/ICETOOL

 


Similar Topics
Topic Forum Replies
No new posts Sort w/OUTREC Question DFSORT/ICETOOL 2
No new posts Getting error S000 U0016 (Cn Internal... JCL & VSAM 4
No new posts Is the Output of Sort/Join dependent ... DFSORT/ICETOOL 2
No new posts Trying to use sort to do two function... DFSORT/ICETOOL 14
No new posts Sort to extract lines DFSORT/ICETOOL 8
Search our Forums:

Back to Top