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

Announcements
Qlik Open Lakehouse is Now Generally Available! Discover the key highlights and partner resources here.
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

how to pass a string using tMap

Hello , i have a problem.
I'm trying to insert inside a table of a database a string that i define. I use this syntax.
In the tMap on the coloumn that i need i pass this value "my string". But the insert in the table give mi an error.
It's wrong to pass a string in this way?
Thank you

Labels (2)
5 Replies
TRF
Champion II
Champion II

Hi,
Can you share the error message ans maybe the tMap?
Anonymous
Not applicable
Author

Sure, this is the error: Exception in component tPostgresqlOutput_2
[FATAL]: output_project3_0_1.output_project - tPostgresqlOutput_2 L'operazione «batch» 92 INSERT INTO ...("coloumn1","coloumn2","coloum3","problem_coloumn","error") VALUES (300144698,20,30,,error).
I try to put the query in pgAdmin and i get this error:
ERROR:  syntax error at or near ","
LINE 2: ...,"problem_coloumn","error") VALUES (300144698,20,30,,error)
TRF
Champion II
Champion II

You cannot have a double comma in the insert statement. Should looks like VALUES (300144698,20,30,NULL,error) or VALUES (300144698,20,30,'',error)
Share the tMap to see how is completed the value for "problem_coloumn" field.
Anonymous
Not applicable
Author

how i can insert a string in the coloumn errore? 
  0683p000009MGF5.jpg
TRF
Champion II
Champion II

Having a constant (here "errore") is a way.
However, you're sharing the reject flow. Can you share the flow from which rows arrive to tPostgres compponent as it is the place where data are prepared before the database injection?