View previous topic :: View next topic
|
Author |
Message |
Ketan Varhade
Active User
Joined: 29 Jun 2009 Posts: 197 Location: Mumbai
|
|
|
|
Hi,
Is there any way by which we can check the record length of variable using a syncsort ? |
|
Back to top |
|
|
Anuj Dhawan
Superior Member
Joined: 22 Apr 2006 Posts: 6250 Location: Mumbai, India
|
|
|
|
Hello Ketan,
Your question leaves a lot more to know -- is your question same as the original question of the thread? (on the back of which you append your question.)
Please show some example of input and then expected output from that. |
|
Back to top |
|
|
Ketan Varhade
Active User
Joined: 29 Jun 2009 Posts: 197 Location: Mumbai
|
|
|
|
Hi Anuj,
I m new member out here..... Just read that thread n was keen to know that is there any way by which we can determine the record length of any variable........
For eg
we have file of fixed record length and there can be a possibility that we can have different records ...
first rec 12345
2nd rec 123
3rd rec 9
So there are can be possibility that we can rec of different length
So is there any way by which we can know that length of the each record using the sort ….
As we can do the same using in cobol
Read one my be each rec and then use length of rec(x) to length
By this way we can get the record length of each variable .
So My questions is the same as Sandeep has……
It not my project requirement but I just want to know abt this …. So I posted in the same thread
Thanks
Ketan Varhade |
|
Back to top |
|
|
Anuj Dhawan
Superior Member
Joined: 22 Apr 2006 Posts: 6250 Location: Mumbai, India
|
|
|
|
Hi,
Quote: |
we have file of fixed record length and there can be a possibility that we can have different records |
If in above quoted text by "different records" you want to say "variable length records" then that's not correct for a file with RECFM=FB as you stated. That can be true for VB files though.
If this was about VB files, you can show the contents of RDW using the below job:
Code: |
//SHOWV EXEC PGM=ICEMAN
//SYSOUT DD SYSOUT=*
//SORTIN DD DSN=... input file (VB)
//SORTOUT DD SYSOUT=*
//SYSIN DD *
OPTION COPY
OUTREC BUILD=(1,4,1,2,BI,C'|',5)
/* |
input file (VB) can have
Code: |
111 A$$$$345
222 AAAAA12324
444 FFFFF455
555 GGGGG1
888 CCCCC12 |
Sortout will have:
Code: |
16 |111 A$$$$345
18 |222 AAAAA12324
16 |444 FFFFF455
14 |555 GGGGG1
15 |888 CCCCC12 |
And yes, everyone was new once upon a time ... |
|
Back to top |
|
|
enrico-sorichetti
Superior Member
Joined: 14 Mar 2007 Posts: 10872 Location: italy
|
|
|
|
Quote: |
And yes, everyone was new once upon a time ... |
but the main issue is being new with an expired warranty |
|
Back to top |
|
|
|