Not sure why this doesn't work. Can you spot the issue?
I just want to check if the timestamp coming across ("Observation_Date_Time") is null or not. If its null, write "1970-1-1 00:00:00", otherwise convert the timestamp from unix to human readable.
Works fine without the IF statement. "Invalid Expression" error with the IF.
if(
items(
'For_each_childRecord')?
['attributes']?
['Observation_Date_Time']
= null, //also tried = 0 //same error "invalid expression"
'1970-1-1 00:00:00',
addseconds(
'1970-1-1',
Div(
items(
'For_each_childRecord')?
['attributes']?
['Observation_Date_Time'],
1000
),
'yyyy-MM-dd hh:mm:ss'
)
)