Portal | Manuals | References | Downloads | Info | Programs | JCLs | Master the Mainframes
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Usergroups Profile Log in to check your private messages Log in
 

 

if the number is less than 8 i need to suffix the zeros for

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> COBOL Programming
View previous topic :: :: View next topic  
Author Message
EnjoyMF

New User


Joined: 27 May 2005
Posts: 88

PostPosted: Mon Aug 29, 2005 4:14 pm    Post subject: if the number is less than 8 i need to suffix the zeros for
Reply with quote

Hi all

i have a alphanumeric field of length 8,
the input to this field is a account number and the account number can vary from 4 to 8 length
if the number is less than 8 i need to suffix the zeros for them

example
(B - spaces ) 1234BBBB then output should be 00001234
12345BBB then output should be 00012345

plz can any one sugguest me a simple logic for that

Regards
prasad
Back to top
View user's profile Send private message

gowtham_srgp

New User


Joined: 09 Jun 2005
Posts: 38

PostPosted: Mon Aug 29, 2005 4:46 pm    Post subject: Re: cobol logic
Reply with quote

EnjoyMF wrote:
Hi all

i have a alphanumeric field of length 8,
the input to this field is a account number and the account number can vary from 4 to 8 length
if the number is less than 8 i need to suffix the zeros for them

example
(B - spaces ) 1234BBBB then output should be 00001234
12345BBB then output should be 00012345

plz can any one sugguest me a simple logic for that

Regards
prasad



hai. you get the alphanumeric data and move it to a numeric identifier. the leading zeroes will be present. if there happens to be a alphaetic entry for the account number, there can be a problem of soc-7...


corrections welcomed.......


gowtham
Back to top
View user's profile Send private message
mmwife

Super Moderator


Joined: 30 May 2003
Posts: 1592

PostPosted: Wed Aug 31, 2005 5:16 am    Post subject:
Reply with quote

Hi Prasad,

When asking for logic help you should show us what you have tried and what probs you encountered.

Then we can make suggestions that you can try and report back on your progress.

Asking us to solve your problem for you is not the way to go. You'll learn a lot more if you try to solve it yourself.
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 -> COBOL Programming All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts Sequence number add in SORT pshongal SYNCSORT 3 Fri Sep 02, 2016 3:32 pm
No new posts Casting a Binary Number to Numeric in... Bob Steinkraus Java & MQSeries 6 Tue Aug 09, 2016 5:58 pm
No new posts GDG vsersion number change Raghu navaikulam JCL & VSAM 5 Fri May 27, 2016 4:49 pm
No new posts Join key - Populate Zeros when Unpair... rexx77 DFSORT/ICETOOL 6 Thu May 12, 2016 12:22 am
No new posts CPU time Vs Number of records Nileshkul JCL & VSAM 5 Mon May 09, 2016 4:05 pm


Facebook
Back to Top
 
Mainframe Wiki | Forum Rules | Bookmarks | Subscriptions | FAQ | Tutorials | Contact Us