Page 1 of 1

Mapping decimal fields

Posted: Wed Nov 26, 2003 12:41 pm
by powerinmind2
Hi,
i have a problem. i have a seq file with a decimal field.

Ex. 1234567.1234

I want read this field. I have set Lenght to 7 and Scale to 4 but i cannot read this field!! I read this error: "Field "COL2" has import error and no default value; data: {1 2 3 4 5 6 7 . 1 2 3 4}"

Help me!

Massimiliano

Posted: Wed Nov 26, 2003 12:45 pm
by 1stpoint
Try changing it to Varchar(50).

Posted: Wed Nov 26, 2003 12:47 pm
by kcbland
I'm curious, you show a job type of parallel but a platform of Windows? Your error looks like a PX error, but you can't run PX on Windows.

Posted: Wed Nov 26, 2003 12:49 pm
by powerinmind2
1stpoint wrote:Try changing it to Varchar(50).
I cannot because i verify the field. If data into field are different type, i reject the record! :-(

Posted: Wed Nov 26, 2003 12:52 pm
by powerinmind2
kcbland wrote:I'm curious, you show a job type of parallel but a platform of Windows? Your error looks like a PX error, but you can't run PX on Windows.
Sorry Ken!! The platform is UNIX!!! Have u an idea for my problem? I have set the options of the field but i have problem too!!

Re: Mapping decimal fields

Posted: Wed Nov 26, 2003 12:56 pm
by Teej
powerinmind2 wrote:Hi,
i have a problem. i have a seq file with a decimal field.

Ex. 1234567.1234

I want read this field. I have set Lenght to 7 and Scale to 4 but i cannot read this field!! I read this error: "Field "COL2" has import error and no default value; data: {1 2 3 4 5 6 7 . 1 2 3 4}"
That's because it's a length of 12, not 7. Really 11, but 12 due to the fact that you're reading it from a flat file so must count the period.

-T.J.