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
 

 

Icetool Select / Splice with sort fields

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> DFSORT/ICETOOL
View previous topic :: :: View next topic  
Author Message
mgl

New User


Joined: 12 Dec 2005
Posts: 27
Location: Belgium

PostPosted: Tue Jan 23, 2007 8:10 pm    Post subject: Icetool Select / Splice with sort fields
Reply with quote

Hi,

In manual, it's said that 'USING' parameter of 'SPLICE' or 'SELECT' is for a DDname pointing to Dfsort statement, basically INREC, INCLUDE or OUTFIL statements. But it is not explained the result of using SORT or SUM statement.
I did some test and was really happy to saw that using a SORT FIELDS statement in my ddcntl with a SPLICE, the generated (by splice) SORT FIELDS command is ignored and i splice my dataset with regards to input generated. It allows doing a 'splice by group'.
It is not the same with select, using a sort statement with select, my sort statement is ignored and i have a sort generated by select.

Checking in my sysout i don't see any difference in the information given. In both case, I receive the syntax of my ddcntl followed by the sort fields generated, followed by call to E35 exit.

With the last ptf we loose one opportunities to modify our input before SPLICE or SELECT with outrec not more allowed. I had to modify some job, and often had to add a step or a copy command in my icetool. I hope here to keep 'splice by group' opportunity (and why not 'select by group' if possible).

Therefore i would be happy if anybody can let me know where to have a good description of the use of select and splice, or if not, ask Frank if it is possible for him to ask IBM to evaluate the work requested to avoid the generation of a sort statement in case of one coded in the dd pointed by the 'using' parm.

I join here a doc file of a job using the 'splice by group'

Many thanks in advance,
Michel.
Back to top
View user's profile Send private message

mgl

New User


Joined: 12 Dec 2005
Posts: 27
Location: Belgium

PostPosted: Tue Jan 23, 2007 8:42 pm    Post subject: Re: Icetool Select / Splice with sort fields
Reply with quote

Sorry, it seems that i did a mistake, SELECT take also in account the SORT FIELDS statement.

Regards,
Michel.
Back to top
View user's profile Send private message
Frank Yaeger

DFSORT Moderator


Joined: 15 Feb 2005
Posts: 7130
Location: San Jose, CA

PostPosted: Tue Jan 23, 2007 10:17 pm    Post subject:
Reply with quote

You can use a SORT statement with both SELECT and SPLICE. An OUTREC statement was never allowed with SELECT or SPLICE, but OUTFIL statement(s) were always allowed. With the April, 2006 DFSORT PTF, we now issue a message to prevent the use of an OUTREC statement whereas before it would usually result in a S0C4 abend. Also with the April, 2006 DFSORT PTF, we now allow INREC with SELECT and SPLICE which wasn't allowed before.

The DFSORT statements that are allowed and not allowed with SELECT are discussed here:

http://publibz.boulder.ibm.com/cgi-bin/bookmgr_OS390/BOOKS/ICE1CA20/6.11?DT=20060615185603

The DFSORT statements that are allowed and not allowed with SPLICE are discussed here:

http://publibz.boulder.ibm.com/cgi-bin/bookmgr_OS390/BOOKS/ICE1CA20/6.13?DT=20060615185603
Back to top
View user's profile Send private message
mgl

New User


Joined: 12 Dec 2005
Posts: 27
Location: Belgium

PostPosted: Tue Jan 23, 2007 10:59 pm    Post subject: Re: Icetool Select / Splice with sort fields
Reply with quote

Hi,
Many thanks for the answer, but the extract of the book you mentioned don't speak about SUM (Allowed or not ?) and don't allow SORT for the SPLICE.
But up to now i didn't encounter any problem with sort statement in a splice, and as you can see in the sample i joined, it can be really useful.

Best regards,
Michel.
Back to top
View user's profile Send private message
Frank Yaeger

DFSORT Moderator


Joined: 15 Feb 2005
Posts: 7130
Location: San Jose, CA

PostPosted: Wed Jan 24, 2007 12:28 am    Post subject:
Reply with quote

Oops. You're right. I forgot what I wrote. icon_redface.gif A SORT statement can be used "officially" with SELECT as discussed. A SORT statement cannot be used "officially" with SPLICE, but there are probably cases where it will work ok.

A SUM statement cannot be used "officially" with SELECT or SPLICE, but there are probably cases where it will work ok. I suspect that OUTFIL with SECTIONS, which is supported, can be used to do whatever you'd want to do with SUM.

I took a quick look at your job. You're overriding SPLICE's SORT statement with SORT FIELDS=COPY. That will work as long as your records are already in sorted order by the ON fields.

An OUTREC statement with SPLICE really isn't needed since OUTFIL BUILD, OVERLAY and IFTHEN are available.
Back to top
View user's profile Send private message
Alain Benveniste

New User


Joined: 14 Feb 2005
Posts: 88

PostPosted: Wed Jan 24, 2007 2:23 pm    Post subject:
Reply with quote

Frank wrote :
Quote:

Oops. You're right. I forgot what I wrote. A SORT statement can be used "officially" with SELECT as discussed. A SORT statement cannot be used "officially" with SPLICE, but there are probably cases where it will work ok.

I hope it will become "official" soon icon_biggrin.gif
Back to top
View user's profile Send private message
mgl

New User


Joined: 12 Dec 2005
Posts: 27
Location: Belgium

PostPosted: Wed Jan 24, 2007 2:27 pm    Post subject: Re: Icetool Select / Splice with sort fields
Reply with quote

Many thanks for the answer Frank,

I understand that if you code yourself the sort statement, you modify the base of the Splice or Select way to work and of course modify the result produced( with possibility of abend0c4 or abend0c1) . I am just afraid that IBM can rewrite the code or avoid the use of this possibility from one day to another. That's allow use of these options only for temporary job's.

By the way, my idea for the sum was to do a Select alldups on(fieldA), with in ddcntl a sort fields (fieldA,fieldB,fieldC) with sum fields(none).
Example, fieldA is dataset name from smf16, fieldb is step name from smf16 and fieldc is job name of smf16. I expect so in one select to receive all the access to a dataset by Dfsort but avoid entries for job rerun.
I will try and .... see but anyway i know that it is not official so ... no support in the future.

Best regards,
Michel.
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 -> DFSORT/ICETOOL All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts Syncsort Help to group fields sudhakarraju SYNCSORT 6 Thu Dec 29, 2016 1:38 am
No new posts Limit duplicate records in the SORT pshongal SYNCSORT 6 Mon Nov 21, 2016 12:54 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
No new posts Two Selects in a single select query Rohit Umarjikar DB2 1 Fri Nov 04, 2016 8:46 pm
No new posts Access SQLCA fields inside a stored p... gangapd DB2 4 Thu Oct 27, 2016 10:20 am


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