I am attempting to convert an input file delimited by "¦', and converting those numeric input fields to four-byte binary fields.
Using the included JCL, (with no attempt at conversion), the resulting parsed fields a left-justified characters. Is it possible to parse these fields so the resulting fields are four-byte binary?
So, during the "BUILD" phase, is it possible, to convert, (for instance), "CONID" directly to a four-byte binary field ?
The fields in question are those that end in "...ID".
UNIT,%00
TEAM,%01
RM,%02
CONID,%03
INTCSTID,%04
CONNAME,%05
CUSTNAME,%06
CIN,%07
CIS,%08
APPID,%09
FACID,%10
SC,%11
AN,%12
BSORT,%13
BAN,%14
//SYSIN DD *
SORT FIELDS=COPY
INREC PARSE=(UNIT=(ENDBEFR=C'¦',FIXLEN=60),
TEAM=(ENDBEFR=C'¦',FIXLEN=60),
RM=(ENDBEFR=C'¦',FIXLEN=90),
CONID=(ENDBEFR=C'¦',FIXLEN=15),
INTCSTID=(ENDBEFR=C'¦',FIXLEN=15),
CONNAME=(ENDBEFR=C'¦',FIXLEN=80),
CUSTNAME=(ENDBEFR=C'¦',FIXLEN=120),
CIN=(ENDBEFR=C'¦',FIXLEN=20),
CIS=(ENDBEFR=C'¦',FIXLEN=20),
APPID=(ENDBEFR=C'¦',FIXLEN=15),
FACID=(ENDBEFR=C'¦',FIXLEN=15),
SC=(ENDBEFR=C'¦',FIXLEN=6),
AN=(ENDBEFR=C'¦',FIXLEN=8),
BSORT=(ENDBEFR=C'¦',FIXLEN=15),
BAN=(ENDBEFR=C'¦',FIXLEN=8)),
BUILD=(SC,AN,
C' KEY ',UNIT,TEAM,RM,
C' CONID ',CONID,
C' INTCSTID ',INTCSTID,
C' CIN ',CIN,
C' CIS ',CIS,
C' APPID ',APPID,
C' FACID ',FACID)
TEAM,%01
RM,%02
CONID,%03
INTCSTID,%04
CONNAME,%05
CUSTNAME,%06
CIN,%07
CIS,%08
APPID,%09
FACID,%10
SC,%11
AN,%12
BSORT,%13
BAN,%14
//SYSIN DD *
SORT FIELDS=COPY
INREC PARSE=(UNIT=(ENDBEFR=C'¦',FIXLEN=60),
TEAM=(ENDBEFR=C'¦',FIXLEN=60),
RM=(ENDBEFR=C'¦',FIXLEN=90),
CONID=(ENDBEFR=C'¦',FIXLEN=15),
INTCSTID=(ENDBEFR=C'¦',FIXLEN=15),
CONNAME=(ENDBEFR=C'¦',FIXLEN=80),
CUSTNAME=(ENDBEFR=C'¦',FIXLEN=120),
CIN=(ENDBEFR=C'¦',FIXLEN=20),
CIS=(ENDBEFR=C'¦',FIXLEN=20),
APPID=(ENDBEFR=C'¦',FIXLEN=15),
FACID=(ENDBEFR=C'¦',FIXLEN=15),
SC=(ENDBEFR=C'¦',FIXLEN=6),
AN=(ENDBEFR=C'¦',FIXLEN=8),
BSORT=(ENDBEFR=C'¦',FIXLEN=15),
BAN=(ENDBEFR=C'¦',FIXLEN=8)),
BUILD=(SC,AN,
C' KEY ',UNIT,TEAM,RM,
C' CONID ',CONID,
C' INTCSTID ',INTCSTID,
C' CIN ',CIN,
C' CIS ',CIS,
C' APPID ',APPID,
C' FACID ',FACID)
and the input file, (upto the sixth field) looks like...
UNIT1 TEST¦TEAM1¦RM1¦1234567890¦1234567899¦CONNECTION NAME¦CU
UNIT2 TEST¦TEAM1¦RM1¦1234567890¦1234567899¦CONNECTION NAME¦CU
UNIT2 TEST¦TEAM1¦RM1¦1234567890¦1234567899¦CONNECTION NAME¦CU
UNIT2 TEST¦TEAM1¦RM1¦1234567890¦1234567899¦CONNECTION NAME¦CU
UNIT2 TEST¦TEAM1¦RM1¦1234567890¦1234567899¦CONNECTION NAME¦CU