Hi
Which database type? Mysql? Oracle? or others?
There is a global variable like ((Integer)globalMap.get("tMysqlInput_2_NB_LINE")), we use normally this global variable to check how many lines are returned by the query. For example:
tMysqlInput_1--row1-->tFlowToIterate---->iterate-->tMysqlInput_2--->tLogRow---runIf---tFixedFlowInput--main--tFileOutputDelimited
on tMysqlInput_1:
select AddressId from ListAddress
on tMysqlInput_2:
run a query that uses the ListAddress row's 'AddressId' column as you mentioned.
Set the condition of RunIf:
((Integer)globalMap.get("tMysqlInput_2_NB_LINE"))==0
on tFixedFowInput, generate one line with one column on the schema,
key:value
AddressId
Integer)globalMap.get("row1. AddressId")
Best regards
Shong