Hello,
I’m trying to filter rows of objects in Workshop based on a comparison between two of their properties, both of which are of date
type.
I haven’t been able to find a straightforward way to do this directly within Workshop’s filtering interface. Additionally, when attempting to implement this logic using Python functions in Workshop, it seems that comparing two properties within the same function is not supported.
Could you please advise if there is any method or workaround to filter data by comparing two properties in Workshop?
+) Is there any way to adjust relative timedelta method to specific property, and use it on comparing two properties?
example code
old_REDACTED_lv2 = (
client.ontology.objects.REDACTED
.init_from_object_set_rid(
_old_REDACTED.get_object_set_rid()
)
.where( (REDACTED.delivery_date >= REDACTED.notification_date) ) ### -> this code return error
# .where(REDACTED.delivery_date >= REDACTED.notification_date + timedelta(365)) ## -> what i really want to do
error log
ValueError: cannot process 'deliveryDate >= Property['notificationDate']': 'Property['notificationDate']' should be a 'date'.
Thank you