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
 
Easytrieve - Move alphanumeric field to numeric

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> CA Products
View previous topic :: :: View next topic  
Author Message
nicedaisy

New User


Joined: 18 Jan 2010
Posts: 1
Location: Chennai

PostPosted: Fri Mar 11, 2011 9:02 pm    Post subject: Easytrieve - Move alphanumeric field to numeric
Reply with quote

Hi,

I want to move alphanumeric field to numeric like shown below:

WS-A 10 A VALUE '00164.3530'

TO

WS-B 11 N 6

I tried to redefine the WS-A variable in different ways as shown below abd tried to move WS-A to WS-D and WS-D to WS-B but none of them worked(got soc7 error).

WS-C W 10 A
WS-D WS-C 10 N

WS-C W 10 A
WS-D WS-C 10 N 6

WS-C W 10 A
WS-D WS-C 9 P 6

It would be great if somebody can help me with this, please?

Thanks much!
Back to top
View user's profile Send private message

Ronald Burr

Active User


Joined: 22 Oct 2009
Posts: 293
Location: U.S.A.

PostPosted: Fri Mar 11, 2011 10:28 pm    Post subject: Re: Easytrieve - Move alphanumeric field to numeric
Reply with quote

nicedaisy wrote:
Hi,

I want to move alphanumeric field to numeric like shown below:

WS-A 10 A VALUE '00164.3530'

TO

WS-B 11 N 6


With a WS-A value of '00164.3540', what it the value you hope to see in WS-B after the move?
Back to top
View user's profile Send private message
dick scherrer

Site Director


Joined: 23 Nov 2006
Posts: 19270
Location: Inside the Matrix

PostPosted: Fri Mar 11, 2011 10:39 pm    Post subject:
Reply with quote

Hello and welcome to the forum,

As far as i know, there is no "direct move" that will do this in Easytrieve. There may be such, but if there is, i'm not aware of it.

Will the data aleays be 99999.9999 format? If so redefine the 10-byte field as a 5-byte zoned-decimal, a filler, and a 4-byte zoned-decimal. Then (if the data is guaranteed to be valid) calculate the target field from the 2 pieces. If the data is questionable, validate both pieces before using them.

The data shows 4 decimal places but some of the "target fields) have 6.
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 -> CA Products All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts How to include a particular field val... sakrat DFSORT/ICETOOL 8 Fri Apr 06, 2018 8:27 pm
No new posts Sort numeric fields with trailing spaces sancraig16 SYNCSORT 7 Tue Apr 03, 2018 1:21 am
No new posts Extract the records with a PD field's... sudhakar84 DFSORT/ICETOOL 11 Mon Apr 02, 2018 7:26 pm
No new posts Searching a table for the field name? socker_dad COBOL Programming 8 Sat Mar 31, 2018 2:57 am
No new posts RMM Cannot move a volume from SHELF l... tspr52 IBM Tools 0 Thu Mar 01, 2018 3:48 pm

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