10-26-2021 02:39 PM
Hi All,
I am trying to load a new redshift table which I have created. While validation, I am getting
“error_code”: 1207
“error_message”: "Invalid digit, Value ‘.’, Pos 9, Type: Integer "
“column_value”: "595546349.04 "
I have tried with DOUBLE PRECISION, REAL to alter the column data type of this redshift table, still getting above error. Also used parseFloat() before using redshift for this field, not working and same error. Does anyone know how to address this? Please let me know.
Regards,
Amar
10-28-2021 07:58 AM
Hi Matthew,
I already tried double precision it gave error again. It have integer, decimals, 0.00 & Null. Does double precision while creating table will work? Kindly help.
Regards,
Amardeep Shanmugam.
10-28-2021 09:50 AM
I’m able to insert all of these values into a DOUBLE PRECISION field. When you say you tried double precision and it gave you an error, did you alter the data type of the database field to a DOUBLE PRECISION ? That’s what I thought you meant earlier, but now not sure we are referring to the same thing. The 1207 error you showed earlier was pretty specific about the reason for failure reporting the value and data type of the field it was trying to insert into.
CREATE TABLE t1207 (
id int,
bigdecimal double precision
)
JSON payload.
[
{
"id": 1,
"bigdecimal": "256800000000"
},
{
"id": 2,
"bigdecimal": 0.00
},
{
"id": 3,
"bigdecimal": "64290705800.14"
},
{
"id": 4,
"bigdecimal": "6515871900000"
},
{
"id": 5,
"bigdecimal": "76476000000"
},
{
"id": 6,
"bigdecimal": "87351502445.84"
},
{
"id": 7,
"bigdecimal": null
}
]
Be aware that you can also create a support ticket for help resolving your issue:
That said, I have no problem continuing to try to help here. I think you’re close.
10-28-2021 10:30 AM
Thanks Matthew. It works now.
Regards,
Amar.