Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
I am trying to show my SP result to tlogrow component
For this i have joined tDBSP and Select Mysql Server and configure it for my SP in the database
Then i joined this component to tlogrow component but empty result
Is there anyway to do it?
Hello @sm
What kind of result your Stored Procedure returns in Database when Stored Procedure is executed there?
Example, If your stored procedure prints the result of a table as output OR If Stored Procedure prints its end result which is captured in a local variable.
If your scenario is as per the above example, then
In your Stored Procedure, whichever result you want to pass to Talend add an alias name to it ->
SELECT @Result AS PasstoTalend -- where @Result is your local variable which stores result that you want to pass to Talend
OR
SELECT Column-Name AS PasstoTalend FROM Table-Name
In Talend Job instead of using tMSSQLSP use tMSSQLInput and in Query tab -> call your Stored Procedure (Exec .... ) and in Edit schema add -> PasstoTalend as string type column.
Connect tMSSQLInput to tLogRow and see if the expected result is printed.
You can also try the above approach using your existing tMSSQLSP -> tLogRow
In my case, tMSSQLInput had worked. So you can use any of them. What's important is adding alias name of the column which you have specified in your Stored procedure i.e. PasstoTalend to the Edit schema.
Hi !
I don't have the content of your stored procedure, but I think the main problem is that output of SP is for the client, not for Talend.
You need to redirect it to a file or if possible (not used to it) to standard output (screen).
Hope it helps
Hi,
Could you please refer the sample scenario given in the below link and try to setup on similar lines? Please verify whether you have selected IsFunction option in your component and mapped the data to output column.
https://help.talend.com/reader/mjoDghHoMPI0yuyZ83a13Q/HOP2YjpwNwtjy3I8LOv_ow
Warm Regards,
Nikhil Thampi
Please appreciate our Talend community members by giving Kudos for sharing their time for your query. If your query is answered, please mark the topic as resolved
Do i need a separate input connection for the table with select query ?
Even tough my SP is using same Select query
Hi @sm
If the data is coming from SP component, then you do not need to use the input component separately. It depends on how you are orchestrating the flow.
Warm Regards,
Nikhil Thampi
Please appreciate our Talend community members by giving Kudos for sharing their time for your query. If your query is answered, please mark the topic as resolved
I did not check the Isfunction , should i do this ?
Hi,
If you have to transfer data between Stored proc and Talend schema, you will have to use it.
Warm Regards,
Nikhil Thampi
Please appreciate our Talend community members by giving Kudos for sharing their time for your query. If your query is answered, please mark the topic as resolved
Hi
But still it gives me empty drop down in the Return Result in
Hello @sm
What kind of result your Stored Procedure returns in Database when Stored Procedure is executed there?
Example, If your stored procedure prints the result of a table as output OR If Stored Procedure prints its end result which is captured in a local variable.
If your scenario is as per the above example, then
In your Stored Procedure, whichever result you want to pass to Talend add an alias name to it ->
SELECT @Result AS PasstoTalend -- where @Result is your local variable which stores result that you want to pass to Talend
OR
SELECT Column-Name AS PasstoTalend FROM Table-Name
In Talend Job instead of using tMSSQLSP use tMSSQLInput and in Query tab -> call your Stored Procedure (Exec .... ) and in Edit schema add -> PasstoTalend as string type column.
Connect tMSSQLInput to tLogRow and see if the expected result is printed.
You can also try the above approach using your existing tMSSQLSP -> tLogRow
In my case, tMSSQLInput had worked. So you can use any of them. What's important is adding alias name of the column which you have specified in your Stored procedure i.e. PasstoTalend to the Edit schema.