My jdbc_streaming produce an array like this
"attachment": [
{
"departmentid" : "2"
}]
now i would like to lookup my db using the departmentid, and get the equivalent department name and put it as below
"attachment": [
{
"departmentid" : "2",
"department" : [
{
"department": "dept2"
"other_details_here": ""
}
]
}}
I can do this query if my attachment is flat,
Select departmentName as department from Department where id = :departmentid