Converting numeric data to COBOL Comp-3

Post questions here relative to DataStage Server Edition for such areas as Server job design, DS Basic, Routines, Job Sequences, etc.

Moderators: chulett, rschirm, roy

Post Reply
harisukumaran
Participant
Posts: 2
Joined: Wed Jun 16, 2004 4:23 pm

Converting numeric data to COBOL Comp-3

Post by harisukumaran »

I found several posts on this forum about converting packed data to numeric but could find any about doing the reverse. That happens to be what I am supposed to do. I looked in online documentation but could not find exactly what I am looking for. The SDK has a function for converting packed to integer but not the reverse. I would be a tremendous help if some one could share information about how this can be accomplished.
jseclen
Participant
Posts: 133
Joined: Wed Mar 05, 2003 4:19 pm
Location: Lima - Peru. Sudamerica
Contact:

Re: Converting numeric data to COBOL Comp-3

Post by jseclen »

Hi,

Are you using Job Mainframe?

In the Job Mainframe constraint you must to define the next conversion

CAST(Campo AS DECIMAL(18, 4) ).
Saludos,

Miguel Seclén
Lima - Peru
harisukumaran
Participant
Posts: 2
Joined: Wed Jun 16, 2004 4:23 pm

Post by harisukumaran »

I am just using a server job (not mainframe stage). I have used OConv with MP to try to do the conversion but does not work.
jwhyman
Premium Member
Premium Member
Posts: 13
Joined: Fri Apr 09, 2004 2:18 am

Post by jwhyman »

The reason the SDK has it this way is because most customers read from mainrames nd not send data to them. The SDK comes with source, you have the algorithm one way, work out how to reverse it.
Post Reply