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
 

 

Syncsort Keyword: SORTED

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> JCL & VSAM
View previous topic :: :: View next topic  
Author Message
janusman

New User


Joined: 09 Sep 2008
Posts: 31
Location: India

PostPosted: Mon Oct 24, 2011 9:27 pm    Post subject: Syncsort Keyword: SORTED
Reply with quote

Hi

My shop has SYNCSORT 1.4

It would be great if someone can can clarify my understanding on how sort works.

In order for a JOINKEYS sort to work properly, the files should be sorted based on the keys am matching with.

e.g.

Code:
JOINKEYS FILE=F1,FIELDS(10,10,A)
JOINKEYS FILE=F2,FIELDS(01,10,A)


If I have File1 already sorted in (10,10,ch,a) - then it is better to specify "SORTED" keyword - Right?

If I do not have the file1 sorted by the matching key- and If I use the above code snippet - will the sort card take care of internally sorting it by itself? or - I still need to have the File1 sorted before this step?
Back to top
View user's profile Send private message

Escapa

Senior Member


Joined: 16 Feb 2007
Posts: 1399
Location: IL, USA

PostPosted: Mon Oct 24, 2011 9:37 pm    Post subject:
Reply with quote

Code:
If I have File1 already sorted in (10,10,ch,a) - then it is better to specify "SORTED" keyword - Right?

What does syncsort documentation say about SORTED clause?
Back to top
View user's profile Send private message
janusman

New User


Joined: 09 Sep 2008
Posts: 31
Location: India

PostPosted: Mon Oct 24, 2011 9:47 pm    Post subject:
Reply with quote

I do not have the syncsort documentation with me now.

but - If I remember correctly, if the files are already sorted based on the keys, it is better to give "SORTED" keyword.

I tried a few simple tests with unsorted files and giving JOINKEYS similar to above - and it returns the result as expected but in sorted order given in JOINKEYS sort card.

So - I would safely assume my understanding is correct - but - just wanted to clarify.
Back to top
View user's profile Send private message
superk

Moderator Team Head


Joined: 26 Apr 2004
Posts: 4648
Location: Raleigh, NC, USA

PostPosted: Mon Oct 24, 2011 9:56 pm    Post subject: Reply to: Syncsort Keyword: SORTED
Reply with quote

Quote:

SORTED Parameter (Optional)
By default, SyncSort will presume that the records in the file are not presequenced per the JOINKEYS FIELDS specified. If the records are already collated in the proper sequence (sorted as binary fields, with the first field being the major field and the subsequent fields being progressively less significant fields), the SORTED parameter can be specified to improve the application's performance.

SyncSort will sequence check each input file according to its JOINKEYS fields. If the SORTED parameter of the JOINKEYS statement was specified to indicate that the file was presorted and the sequence check fails, SyncSort will issue a critical error message containing the file number.

The record number within the file will also be in the error message text whenever the INCLUDE/OMIT parameter of the JOINKEYS statement was
not specified.
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: Mon Oct 24, 2011 10:06 pm    Post subject:
Reply with quote

Hello,

Quote:
I do not have the syncsort documentation with me now.
Then you need to get it. . .

If your organization is licensed to use the product, all of the material is available free from Syncsort Support.
Back to top
View user's profile Send private message
janusman

New User


Joined: 09 Sep 2008
Posts: 31
Location: India

PostPosted: Mon Oct 24, 2011 10:09 pm    Post subject:
Reply with quote

Thanks Superk for the clarification.

Dick - I am working on getting that. 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: Mon Oct 24, 2011 10:32 pm    Post subject: Reply to: Syncsort Keyword: SORTED
Reply with quote

You're welcome - good luck icon_smile.gif

To me, trying to use a product without documentation is kinda like a mechanic who is missing tools icon_wink.gif

d
Back to top
View user's profile Send private message
superk

Moderator Team Head


Joined: 26 Apr 2004
Posts: 4648
Location: Raleigh, NC, USA

PostPosted: Tue Oct 25, 2011 12:46 am    Post subject: Reply to: Syncsort Keyword: SORTED
Reply with quote

I requested a copy of my Syncsort documentation in the first week of this new position at a new company, and had it within about 48 hours.
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 -> JCL & VSAM 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 syncsort: copy lines after the keyword shreya19 SYNCSORT 7 Fri Dec 02, 2016 9:47 am
No new posts Syncsort - Hard coded Value in output PORYES SYNCSORT 1 Thu Nov 03, 2016 9:23 am
No new posts Syncsort - NULL in Integer field chec... nartcr SYNCSORT 4 Thu Oct 06, 2016 6:47 am
No new posts ICETOOL/SYNCSORT - SYSPRINT output nartcr DFSORT/ICETOOL 17 Wed Oct 05, 2016 10:46 pm


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