IBM Mainframe Forum Index
 
Log In
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Register
 

Count the number of characters in a field in Easytrieve


IBM Mainframe Forums -> CA Products
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
Jag Badal

New User


Joined: 25 Jun 2020
Posts: 6
Location: UK

PostPosted: Fri Nov 04, 2022 5:52 pm
Reply with quote

Hello,

I'm new to easytrieve and I'm trying to figure out a way to count the number of characters in a field.

For Example - We have a XYZ field with 10 Characters. If the the data in this field is less than 5 characters i.e. 12345 then the O/P should look like XXXXXXXX45. If it has 10 characters i.e. ABCD567890 then the O/P should look like ABXX5XXX90.

Using Cobol, this would have been an easy ask - I would have used inspect and reference modification to achieve my goal. However, I need to write this piece of logic using easytrieve.

Is there a way to count the number of characters in a field in Easytrieve ?
Back to top
View user's profile Send private message
Jag Badal

New User


Joined: 25 Jun 2020
Posts: 6
Location: UK

PostPosted: Fri Nov 04, 2022 7:47 pm
Reply with quote

Never mind, resolved it.

Used a workaround for it i.e. arrays, looping and concatenation.

Thank you.
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic View Bookmarks
All times are GMT + 6 Hours
Forum Index -> CA Products

 


Similar Topics
Topic Forum Replies
No new posts Help required to reset decimal points... DFSORT/ICETOOL 10
No new posts Overwriting SSN Digits in Easytrieve ... CA Products 0
No new posts Sorting Date Field DFSORT/ICETOOL 4
No new posts CA7 count with DATE variable CA Products 0
No new posts To get the count of rows for every 1 ... DB2 3
Search our Forums:

Back to Top