View previous topic :: View next topic
|
Author |
Message |
pema_yozer
New User
Joined: 16 Feb 2009 Posts: 54 Location: pune
|
|
|
|
sqlcode1,
i have done the same thing and etting output as
[/code]
060109600104992010010703505 - 0000000000000
but for rec 6 i woul dwant output as
060109600104992010010703505 - 0000000000000
|
|
Back to top |
|
|
sqlcode1
Active Member
Joined: 08 Apr 2010 Posts: 577 Location: USA
|
|
|
|
pema_yozer,
I don't see any difference in the 2 output you have posted.
Thanks, |
|
Back to top |
|
|
pema_yozer
New User
Joined: 16 Feb 2009 Posts: 54 Location: pune
|
|
|
|
the spaces are getting filled when i submit the post
060109600104992010010703505packeddecimalspaces0000000000000
060109600104992010010703505packeddecimal0000000000000
packed decimal = 8 byte packed decimal and the
spaces = 8 spaces
but i would require it as the second one
hope this makes sense |
|
Back to top |
|
|
sqlcode1
Active Member
Joined: 08 Apr 2010 Posts: 577 Location: USA
|
|
|
|
I hate to keep this post going but are you still using FB? You had mentioned your question relating to VB was out of curiosity.
Please tell us if you are using VB or FB file. Reason I am asking is you are overlaying some of the fields (following your conversion) for record type 06 or may be I am missing some basic information.
Thanks, |
|
Back to top |
|
|
pema_yozer
New User
Joined: 16 Feb 2009 Posts: 54 Location: pune
|
|
|
|
i'm using FB.
and want the PD to be 8 bytes
i had used over lay to get the format
060109600104992010010703505packeddecimalspaces0000000000000
but this is incorrect due to the space and would require
060109600104992010010703505packeddecimal0000000000000
i think build should be used for this. |
|
Back to top |
|
|
smijoss
Active User
Joined: 30 Aug 2007 Posts: 114 Location: pune
|
|
|
|
u keep confusing between VB and FB
Code: |
//SORT01 EXEC PGM=SORT
//SORTIN DD DISP=SHR,DSN=YOURID..FB.LRECL54
//SORTOUT DD DSN=YOURID.FB.LRECL54.CNVT,
// DISP=(,CATLG,DELETE),
// UNIT=SYSDA
//SYSIN DD *
INREC IFTHEN=(WHEN=(01,02,CH,EQ,C'03'),
OVERLAY=(23:23,16,UFF,TO=PD,LENGTH=08,8X)),
IFTHEN=(WHEN=(01,02,CH,EQ,C'05'),
OVERLAY=(32:32,07,UFF,TO=PD,LENGTH=03,4X)),
IFTHEN=(WHEN=(01,02,CH,EQ,C'06'),
OVERLAY=(28:28,16,UFF,TO=PD,LENGTH=08,44,14,8X)),
IFTHEN=(WHEN=(01,02,CH,EQ,C'07'),
OVERLAY=(33:33,16,UFF,TO=PD,LENGTH=08,8X))
SORT FIELDS=COPY
/*
//SYSOUT DD SYSOUT=*
//* |
|
|
Back to top |
|
|
pema_yozer
New User
Joined: 16 Feb 2009 Posts: 54 Location: pune
|
|
|
|
thanks..
works perfectly |
|
Back to top |
|
|
pema_yozer
New User
Joined: 16 Feb 2009 Posts: 54 Location: pune
|
|
|
|
smijoss
could you plese let me know
what 44 and 14 signify |
|
Back to top |
|
|
pema_yozer
New User
Joined: 16 Feb 2009 Posts: 54 Location: pune
|
|
|
|
pema_yozer wrote: |
smijoss
could you plese let me know
what 44 and 14 signify |
ok it figured out.. thanks again guys |
|
Back to top |
|
|
smijoss
Active User
Joined: 30 Aug 2007 Posts: 114 Location: pune
|
|
|
|
OVERLAY=(28:28,16,UFF,TO=PD,LENGTH=08,44,14,8X))
while copying, it will copy the characters from 1,28
then compress you number from posion 28 to PD and fit it in 8 bytes
in the input, your next data starts from 44 with length 14
and 8x to fill spaces at the end
you could have saved a lot of efforts if you had mentioned things clearly. |
|
Back to top |
|
|
|