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

Announcements
Save $650 on Qlik Connect, Dec 1 - 7, our lowest price of the year. Register with code CYBERWEEK: Register
cancel
Showing results for 
Search instead for 
Did you mean: 
_AnonymousUser
Specialist III
Specialist III

About run if trigger.

I use tRest to call web,and return data, tRest returns schema include Body and ERROR_CODE, if ERROR_CODE if null,means the call is OK.
So I use run if trigger to connect tRest and tjava, condition is : tRest.ERROR_CODE!=null . Talend return error:tRest cannot be resolved to a variable.
So how do i write this condition? I am a bit confused with the way to get value in talend, and can't find it in the document.

Labels (2)
1 Reply
Anonymous
Not applicable

Hi 
Link tRest to a tJavaRow and check the if ERROR_CODE is null there, eg:
tRest--main--tJavaRow--runIf--tJava
on tJavaRow:
if(input_row.ERROR_CODE!=null){
globalMap.put("hasError", true);
}else{
globalMap.put("hasError", false);
}
Set the condition as:
(Boolean)globalMap.get("hasError")

Best regards
Shong