Input Data with Decimal Point



Unicenter CA-Easytrieve Plus Report Generator: CA's information retrieval and data management tool

Input Data with Decimal Point

Postby qz2s4m » Mon Oct 12, 2009 7:40 am

Having difficulty processing input data that contains decimal points.

Data Ex:
----+----1----+----2----+----3----+----4----+----5----
********************************* Top of Data ********
P1800AA12    7EWA6K  7EWA6K7316EXTERNAL000000710.00000
P1800AH0C    EFVJBF  EFVJBF7316EXTERNAL000000016.45000


Trying to code
FILE COURIER FB(200 7400)
 ROOM          6    4 A. 
 RATE         40   12 N 2.


Will generate an A006 error. Though if the RATE field did not have decimal points (i.e. "00000071000"). Then a statement like RATE 40 11 N 2. works just fine. I haven't seen any examples in the manuals as of yet that show any reference to coding DEFINE statements for fields that have decimals in the input data.

Tried using masks, everything I read suggests this if for output of data not input.

Any insight appreciated.

Thanks
Duane
qz2s4m
 
Posts: 7
Joined: Mon Jun 29, 2009 10:08 pm
Has thanked: 0 time
Been thanked: 0 time

Re: Input Data with Decimal Point

Postby dick scherrer » Mon Oct 12, 2009 11:42 pm

Hello,

One way to do what you want is to define the input field as an array and process byte-by-byte.

I'm not aware of an Easytrieve "built-in" that does this. If your organization is licensed to use Easytrieve, CA Support could provide the answer (and maybe eve sample code).
Hope this helps,
d.sch.
User avatar
dick scherrer
Global moderator
 
Posts: 6269
Joined: Sat Jun 09, 2007 8:58 am
Has thanked: 3 times
Been thanked: 93 times


Return to CA-Easytrieve

 


  • Related topics
    Replies
    Views
    Last post