Question to tParseRecordSet

One Star

Question to tParseRecordSet

Hi,
my Job is like this:
tOracleInput -row1-> tOracleRow -row2-> tParseRecordSet_1 -row3-> tLogRow.
In tOracleInput I select some data, with this data I select some rows in tOracleRow and put these rows in an object column. But after the tParseRecordSet the rows are 0. I think the problem is that the query´s recordset has more than one row. Any ideas, solution or alternatives for this Problem?
Thank you for your help.
Moderator

Re: Question to tParseRecordSet

Hi,
Less information to address you issue. Could you give us more information about your job requirement?
In addition, please refer to the component reference tParseRecordSet and its related scenario.
Best regards
Sabrina
--
Don't forget to give kudos when a reply is helpful and click Accept the solution when you think you're good with it.
Community Manager

Re: Question to tParseRecordSet

Hi
I think the problem comes from your job design, can you show us your query on tOracleRow? How do you use the data selected from tOracleInput? To me, the job will look like:
tOracleInput--main(row1)--tFlowToIterate--iterate--tOracleRow--main--tParseRecordSet--main--tLogRow
on tOracleInput:
"select id from tableName where name='shong'"
on tOracleRow:
"select * from tableName where id="+row1.id
Shong
----------------------------------------------------------
Talend | Data Agility for Modern Business
One Star

Re: Question to tParseRecordSet

Hi Sabrina and Shong,
thanks for your help. I think there is one little thing which I overlook.
On tOracleInput i make something like:
"select id, name_id, name from tableName"
on tOracleRow:
"select tableHuman.id, tableHuman.name_id, tablePerson.person_id form tablePerson, tableHuman
Where tableHuman.id = ? AND tableHuman.name_id = ?"
I tried to make the job like shongs, but after the iterate the columns are empty. Just the object column has data.
I try to get the person.id to the other data. The sql statements are very simplified.
I hope with this information you can help, thanks.
Chris
One Star

Re: Question to tParseRecordSet

Hi Community,
just to make the thing clear for me: In tParseRecordSet I can only parse one Row? Or can I parse more than one row?
I just have a Select which get 4 rows as Input and each of this rows should be parameter in a new Select. This new Select has more than this 4 rows as result.
Is there any other component to do this things.
Best regards
Chris
Moderator

Re: Question to tParseRecordSet

Hi,
The function of tParseRecordSet component is parsing a set of records from a database table or DB query and possibly returns single records. So there is only one column chosen from Prev. Comp. Column list. But Please refer to the tParseRecordSet scenarios https://help.talend.com/pages/viewpage.action?pageId=11973851#Raa48944 Scenario 2: Using PreparedStatement objects to query data and Scenario 3: Combining two flows for selective output.
Best regards
Sabrina
--
Don't forget to give kudos when a reply is helpful and click Accept the solution when you think you're good with it.