Skip to main content
Announcements
Introducing Qlik Answers: A plug-and-play, Generative AI powered RAG solution. READ ALL ABOUT IT!
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

insert row into table

Hey guys, i'm a beginner Talend user, so, if you know guys how to insert a row into a data base please get me notified

In fact, i want to insert a new row to a data base table of Microsoft SQL server every time i excute , a new line will be create in the table, which component should i use?

the problem here that i need some variables from a tmap that i've created, 

and i can't link tmap with a trowgenerator, 

here is the request i want to execute
"INSERT INTO [dbo].[CHOIXEXT]
([YX_TYPE]
,[YX_CODE]
,[YX_LIBELLE]
,[YX_ABREGE]
,[YX_LIBRE])
VALUES
(<LA2, nchar(3),>
,< LCW_CodeCHOIXEXT_LA2, nvarchar(17),>
,< MershSubGroupName, nvarchar(105),>
,< MershSubGroup, nvarchar(17),>
,< nv, nvarchar(35),>)
GO"

*"LA2" static String
*"LCW_CodeCHOIXEXT_LA2" request1 result (mentionned in the screenshot below)
*MershSubGroupName form "INV_Product" database
*MershSubGroup form "INV_Product" database
*"nv" static String

thank you for advance guys 

0683p000009M31c.png

Labels (2)
5 Replies
manodwhb
Champion II
Champion II

@9allel22 ,if you wan to execute the insert query ,you can use tDBRow,  as part of flow you were getting data and want to insert you can use tDBOutput.

Anonymous
Not applicable
Author

@manodwhb 

thank's for the feedback, 

i've tried to put tdbRow, but my problem is how to put values in my request (insert) from my tmap

here is screenshots of my job to let you understand more the stuff

 

 

 

MY REQUEST

0683p000009M3H9.png

THE VALUES THAT I WANT TO RECOVER FORM THE TMAP0683p000009M3Np.png

THE LINK BETWEEN TMAP AND TDBROW

0683p000009M3Nu.png

Many regards

manodwhb
Champion II
Champion II

@9allel22 ,form tmap you can connect to tOracleoutput.

Anonymous
Not applicable
Author

not solved yet...

akumar2301
Specialist II
Specialist II

hello ,

 

can you please explain 

which columns are not defined using tMap and why you need trowgenerator for them ?

could you populate those also in tmap?

if yes , you can connect tmap result (rowinsert)

to tdboutput directly ( or tdbrow if you are building insert query )