Skip to main content
Alexandros
Gold ⭐️
Jan 15, 2020 9:21 PM UTC
Solved

PutDatabaseRecord fields don't map database colums

Hi, im trying to upload a CSV to a RedShift database using GetFile->PutDatabaseRecord

 

i'm getting this error:

Captura3.PNG

 

PutDatabaseRecord:

Captura1.PNG

CSVReader (my file got headers, this way and not hardcoding the schema makes everything more easily scalable):

Captura2.PNG

Null string: NULL

 

CSV:

A,B,C,D,E,F,G,H,I
2020-01-15,AX,COD245,NO,PASS,R,,,
2020-01-15,AX,COD235,YES,PASS,R,,,

 

Table with same fields names.

Any idea what i'm doing wrong? Is there any way to look for the query it's making, that will make this more easy to debug.

Thank you!

 

 

Alexandros
Gold ⭐️
Jan 15, 2020 9:36 PM UTC

Solved, PutDatabaseRecord gives you mapping error if the table doesn't exists or if you don't have permissions, hours fighting against the columns names and it was a database problem.

1 reply

Alexandros
AlexandrosAuthorAnswer
Gold ⭐️
Jan 15, 2020 9:36 PM UTC

Solved, PutDatabaseRecord gives you mapping error if the table doesn't exists or if you don't have permissions, hours fighting against the columns names and it was a database problem.

Translate