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

Using Justify statement in SYNCSORT


IBM Mainframe Forums -> JCL & VSAM
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
mushreyas

New User


Joined: 18 Jul 2008
Posts: 59
Location: Bangalore

PostPosted: Tue Aug 16, 2011 8:58 pm
Reply with quote

Hi,

I have to sort first 5 bytes of character data of an input record which is left justified. But before sorting i need to right justify the data and then convert character data (which is always numeric) into binary format.

I have searched for JUSTIFY statement in SYNCSORT manual which i have and couldn't find anything. Hence turning over to you guys for help.
Back to top
View user's profile Send private message
Arun Raj

Moderator


Joined: 17 Oct 2006
Posts: 2481
Location: @my desk

PostPosted: Tue Aug 16, 2011 9:10 pm
Reply with quote

mushreyas,

Show a few sample input records and the expected output out of it along with the input/output file attributes
Back to top
View user's profile Send private message
mushreyas

New User


Joined: 18 Jul 2008
Posts: 59
Location: Bangalore

PostPosted: Wed Aug 17, 2011 6:54 am
Reply with quote

Hi,

Sample Input
Code:

5     
4     
9     
1     
6     

Output should be as below
Code:

00005
00004
00009
00001
00006


And i should convert this to Binary which i will be able to once i do the justification.
Back to top
View user's profile Send private message
mushreyas

New User


Joined: 18 Jul 2008
Posts: 59
Location: Bangalore

PostPosted: Wed Aug 17, 2011 6:55 am
Reply with quote

Input file is of 5 bytes Fixed format and same goes with output file.
Back to top
View user's profile Send private message
dick scherrer

Moderator Emeritus


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

PostPosted: Wed Aug 17, 2011 7:01 am
Reply with quote

Hello,

You should be able to convert these values to binary without the justify (in the BUILD).

Look at the UFF data format maybe.
Back to top
View user's profile Send private message
mushreyas

New User


Joined: 18 Jul 2008
Posts: 59
Location: Bangalore

PostPosted: Wed Aug 17, 2011 9:58 pm
Reply with quote

Hi Dick,

Is the UFF format available with SYNCSORT? If so can it converts the data after justification to Binary.

Should it be coded like below
Code:

OUTREC FIELDS=(1,5,UFF,M11)
Back to top
View user's profile Send private message
dick scherrer

Moderator Emeritus


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

PostPosted: Wed Aug 17, 2011 10:38 pm
Reply with quote

Hello,

What happens when you try it?

'Tis free to try and should cause no problems. . .

A local test will almost always be quicker than the forum. . .

Quote:
Is the UFF format available with SYNCSORT?
Yes, UFF is available with Syncsort.
Back to top
View user's profile Send private message
mushreyas

New User


Joined: 18 Jul 2008
Posts: 59
Location: Bangalore

PostPosted: Thu Aug 18, 2011 9:23 pm
Reply with quote

Thanks Dick. It worked...icon_smile.gif
Back to top
View user's profile Send private message
dick scherrer

Moderator Emeritus


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

PostPosted: Fri Aug 19, 2011 1:48 am
Reply with quote

Good to hear it is working - thank you for letting us know icon_smile.gif

d
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 -> JCL & VSAM

 


Similar Topics
Topic Forum Replies
No new posts Compare only first records of the fil... SYNCSORT 7
No new posts JOIN STATEMENT PERFORMANCE. DFSORT/ICETOOL 12
No new posts Count Records with a crietaria in a f... DFSORT/ICETOOL 5
No new posts DFSORT/SYNCSORT/ICETOOL JCL & VSAM 8
No new posts Relate COBOL statements to EGL statement All Other Mainframe Topics 0
Search our Forums:

Back to Top