View previous topic :: View next topic
|
Author |
Message |
Prajesh_v_p
Active User
Joined: 24 May 2006 Posts: 133 Location: India
|
|
|
|
Hi all,
I have a file which has the input data as below:
+000002368+01
+000034630+01
I need to convert this data into packed decimel format. I used the below sort card and the results I am getting is as below:
1,10,ZD,TO=PD,LENGTH=5,11,3,ZD,TO=PD,LENGTH=2
output data in hex on format(last nibble is coming as F, but expected to be C for postitive numbers and also an E is coming at the start of 01)
....±\.
00038E1
0026F0F
-------
...Ä.\.
00360E1
0043F0F
Any issues wity my sort card?
Thanks! |
|
Back to top |
|
|
Frank Yaeger
DFSORT Developer
Joined: 15 Feb 2005 Posts: 7129 Location: San Jose, CA
|
|
|
|
Those are NOT ZD values. They are FS values.
With DFSORT, the correct control statements would be:
Code: |
OPTION COPY
INREC BUILD=(1,10,FS,TO=PD,LENGTH=5,11,3,FS,TO=PD,LENGTH=2)
|
This would give you the following output (in hex):
Code: |
000002368C001C <--- first record
000034630C001C <--- second record
|
If you're getting an F sign, then you must be using Syncsort, not DFSORT. DFSORT gives a C sign for TO=PD automatically. Syncsort gives an F sign. |
|
Back to top |
|
|
Prajesh_v_p
Active User
Joined: 24 May 2006 Posts: 133 Location: India
|
|
|
|
Hi Frank,
As you said, we have Synsort. sorry for that confusion.
But even with FS, I am getting the result as below:
Code: |
--------
....±.."
00038017
0026F0FF
--------
...Ä...?
00360016
0043F0FF |
Any hints? |
|
Back to top |
|
|
dick scherrer
Moderator Emeritus
Joined: 23 Nov 2006 Posts: 19244 Location: Inside the Matrix
|
|
Back to top |
|
|
|