Portal | Manuals | References | Downloads | Info | Programs | JCLs | Mainframe wiki | Quick Ref
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Profile Log in to check your private messages Log in
 
conversion of pic class value to fixed bin

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> PL/I & Assembler
View previous topic :: :: View next topic  
Author Message
krishnanvenugopal

New User


Joined: 24 May 2006
Posts: 1

PostPosted: Wed May 24, 2006 4:52 pm    Post subject: conversion of pic class value to fixed bin
Reply with quote

when i attempt to convert a pic class value (pic (10)9) into a fixed bin(31,0) 4 blanks r getting padded up to the left of the pic value in fixed bin

eg:
PARSER1: PROC OPTIONS(MAIN);
DCL 1 INPUT1,
2 INPUT_AREA,
5 ACCT_NUM PIC '(10)9' INIT('5000000231'),
2 OUTPUT_BAL,
5 BAL_AMT PIC '(8)S9V(2)9' INIT('50000000.12'),
2 OUTPUT_TRN,
5 TRAN_ID CHAR(10) INIT ('NUTAKKIMUR');
DCL 1 OUT_DATA,
2 INPUT_AREA,
5 ACCT_NUM FIXED DEC (11,0),
2 OUTPUT_BAL,
5 BAL_AMT FIXED DEC(10,2),
2 OUTPUT_TRN,
5 TRAN_ID CHAR(10);
OUT_DATA = INPUT1,BY NAME;
PUT SKIP LIST(INPUT1.INPUT_AREA.ACCT_NUM);
PUT SKIP LIST(OUT_DATA);

in out data the value is obtained padded with 4 blanks to its left
kindly help.....
Back to top
View user's profile Send private message

k_vikram07

New User


Joined: 23 Nov 2005
Posts: 35

PostPosted: Fri Jun 09, 2006 4:44 pm    Post subject:
Reply with quote

could u please explain with output example.
Back to top
View user's profile Send private message
lalgv

New User


Joined: 19 Apr 2006
Posts: 2

PostPosted: Mon Jun 12, 2006 2:15 pm    Post subject: Re: conversion of pic class value to fixed bin
Reply with quote

INPUT1 record length is (
INPUT1.ACCT_NUM - 10 bytes,
INPUT1.OUTPUT_BAL - 10 bytes,
INPUT1.OUTPUT_TRN - 10 bytes.
Then record length of INPUT1 is 30 bytes.

OUT_DATA.ACCT_NUM - 6 bytes,
OUT_DATA.OUTPUT_BAL - 10 bytes,
OUT_DATA.OUTPUT_TRN - 10 bytes.
Then record length of OUT_DATA is 26 bytes.

INPUT1 record length is 30 bytes and OUT_DATA record length is 26 bytes.
Because of 4 bytes difference, you are getting 4 blanks in the OUT_DATA record.
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> PL/I & Assembler All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts question about dfsms management clas... Hervey Martinez IBM Tools 0 Tue Oct 10, 2017 6:19 pm
No new posts Converting Variable block file to Fix... bhavana yalavarthi DFSORT/ICETOOL 10 Tue May 16, 2017 2:20 pm
No new posts Executing OO COBOL program invoking J... Virendra Shambharkar COBOL Programming 2 Tue Jan 10, 2017 6:37 pm
No new posts File Aid to File Manager conversion murali3955 IBM Tools 4 Thu Nov 24, 2016 3:41 pm
No new posts Conversion of a VB file to FB. isssal DFSORT/ICETOOL 1 Mon Oct 31, 2016 10:23 pm

Facebook
Back to Top
 
Job Vacancies | Forum Rules | Bookmarks | Subscriptions | FAQ | Polls | Contact Us