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 fetch the value?

Hi All,
I m trying execute one command/function using tMongoDBRow component and
I wanna process the output returned by tMongoDBRow.
and  I m getting following output when I execute the tMongoDBRow independently.
{ "serverUsed" : "vchngskeoes2-01/10.85.17.35:27017" , "retval" : 0.0 , "ok" : 1.0}
what can be done to get the value stored in retval of above json returned, so that I can use it in the some other component.
Labels (3)
13 Replies
Anonymous
Not applicable
Author

Any one please help me on this whether its feasible or not?
Anonymous
Not applicable
Author

Anonymous
Not applicable
Author

Hi Laurent,
Thanks for your reply 0683p000009MACn.png.
I m getting the following error while trying to use tExtractJsonField.
Error on line 1 of document  : Premature end of file. Nested exception: Premature end of file.
and warning on the component viz., "this component should have a input link(s)"
Thanks,
karthi.
Anonymous
Not applicable
Author

can you show us your job design? 
Anonymous
Not applicable
Author

i've tried to read your json  {"serverUsed" : "vchngskeoes2-01/10.85.17.35:27017" , "retval" : 0.0 , "ok" : 1.0} with any kind of problem.

0683p000009MD7N.png 0683p000009MDF0.png
regards
Anonymous
Not applicable
Author

Hi,
Thank you @umesh and @kzone for you reply.
PFB my job design.

0683p000009MDF5.png
earlier I didn't have tFixedFlow component I just now added after seeing the reply.
but the thing is I m getting the return value as null even though it returns 11.0 as we can see in the output window.
Is it right to connect using "Iterate" or I need to use any global variables (if present).
Anonymous
Not applicable
Author

Hi Karthisam, 
To demonstrate Kzone has used tFixedFlowInput component. you don`t need that, just remove  tFixedFlowInput component and connect MongoDbRow to tExtractJsonField component. it should work. 
Anonymous
Not applicable
Author

Hi Umesh
I have tried to connect tmongodbrow directly but the thing is it has only "iterate" and doesn't have "row" to connect to another component,  because of which I m getter exception which I have already posted.
Will post the screen shot of the original project tomorrow.
Thank you.
Anonymous
Not applicable
Author

have a look at talend help about mongo component :
https://help.talend.com/search/all?query=tMongoDBRow&content-lang=en
I guess that you should use tmongoinput instead of *row.
regards
laurent