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?
Hi,
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.