Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Qlik GA: Multivariate Time Series in Qlik Predict: Get Details
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

Error while loading data from csv to postgres using dynamic schema

Hi,

    I have a requirement to load multiple csv files to different tables in a database. Since the CSVs are dynamic the schema also should be dynamic. I have a Talend licensed version and using dynamic schema. My work flow is like:

tFileList---->tFileInputFlowDelemited-->tMap-->tPostgresqlOutput

 

The schema i defined is 

id : String

others: dynamic

 

The error I am getting at the time of postgres insert is

[ERROR]: local_project.s3_loader_0_1.S3_Loader - tPostgresqlOutput_1 - Batch entry 0 INSERT INTO "public"."S3-Loader-Test" ("id", ) VALUES (576,Test,41:02.4,TRUE,, ) was aborted. Call getNextException to see the cause.
caused by: ERROR: syntax error at or near ")"

 

It is not considering and splitting dynamic field "others" while inserting.

Also if I define schem with only one dynamic column then it is considering the whole CSV row as single column and record and trying to insert. 

 

Could somebody correct me? or point me the right solution?

Labels (3)
1 Solution

Accepted Solutions
Anonymous
Not applicable
Author

Hi,

Thanks for the reply. I found the issue. The issue was related to the field separator. Once corrected it worked.

View solution in original post

3 Replies
Anonymous
Not applicable
Author

Hello,

For the purpose of testing, are you able to get all your output files by using tfileoutputdelimited component?

The work flow looks like:tfilelist-->tfileinputdelimited-->tfileoutputdelimited(Append option checked).

Best regards

Sabrina

Anonymous
Not applicable
Author

Hi,

Thanks for the reply. I found the issue. The issue was related to the field separator. Once corrected it worked.

Anonymous
Not applicable
Author

Hello,

Great it is fixed. Thanks for posting your solution here.

Best regards

Sabrina