Type Conversion Problem

Post questions here relative to DataStage Enterprise/PX Edition for such areas as Parallel job design, Parallel datasets, BuildOps, Wrappers, etc.

Moderators: chulett, rschirm, roy

Post Reply
199542
Participant
Posts: 41
Joined: Sat Dec 29, 2007 2:42 am

Type Conversion Problem

Post by 199542 »

Hi ,
I am having data as below .....

abcd123457020080301470789

field delimiter is none .fixed width file .

actual metadata is as follows :

1st field 1-4 ---- abcd --- char

2nd field 5-11 ---- 1234570 -- number

3rd field 12-19 ---- 20080301 --- date

4th field 20-22 ----- 470 -- decimal (3,1) actual value is 47.0

5th field 23-25 ----- 789 ---number ----

While reading this file from a sequential file , If i am giving metadata as char for all fields , then only I am able to view data otherwise no .
When I am using char for all above fiels then 4th field is displaying like 470 instead of 47.0 .offcourse i can user transformer or modify and do necessary changes ..Other than that , Is there any way to handle it ??
The problem is I have some 150-180 fields , Its very difficult to again convert them in transformer stage .So , It should be handled in sequential file . I request you all to help me out in this problem .

Thanks in advance
gikjpjj
kumar_s
Charter Member
Charter Member
Posts: 5245
Joined: Thu Jun 16, 2005 11:00 pm

Post by kumar_s »

You can specify the Integer (Number) and not as Decimal or without precision.
Impossible doesn't mean 'it is not possible' actually means... 'NOBODY HAS DONE IT SO FAR'
Post Reply