I would like to offload “all measurements of type X with a value >= 30” via Data Hub. I’m struggling with value part.
I’ve tried using
'src."myfragmentmane."myseriesname"."value" >= 30' in the predicate-filter step of the offloading job. However, this statement does not pass the validation.
Is this a supported Offloading predicate filter? What’s the proper syntax?
Have a try with ‘c8y_Temperature.T.value’ > 30
Thanks, I’ve tried:
but no luck so far. Error message is a generic one:
CDHCBEE0441 - Preview computation failed: CDHCBEE0130 - Failed to execute CTAS Job.
Melanie, I just saw your suggestion is using single- rather than double quotes. Can confirm:
'fragment.series.value'>30 passed the valdation. Thanks!
I’m afraid that while you can make the query pass the validation using single-quotes, it doesn’t do what you want. By using single-quotes, you’re creating a string value that is compared against the value 30 – clearly not what you want!
Filtering on a per-fragment/series value is not properly supported (due to the nature of our internal data model in the operational store). There is a way to do it, but I won’t post the solution here as it is nothing I’d recommend to do. DM me if you really need it.
Filtering on custom attributes is supported and simple – the only thing to remember is that if the attribute you want to filter on is nested (i.e. a JSON Object itself), you need to prepend src. to the expression and then “drill” into the structure using dot notation (e.g., src.myObject.myAttribute > 5)
Thanks! I’ve also just realized that the predicate was accepted using single-quotes - however, it indeed didn’t filter what I desired. For the moment I was mainly interested if it is a supported use case or a matter of missconfiguration => which is answered now.
This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.