-
Notifications
You must be signed in to change notification settings - Fork 2
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Determining unset or empty []string attribute #31
Comments
Can you clarify the use case? I'm not following how "we want backwards compatibility with old data" would lead to querying for The error message you're seeing seems like it needs to be improved, it should read something like |
I was intending to have a query filter that looked for records with the attribute set OR the attribute entirely unset (implying it was legacy data, which would be backfilled over time, and for which it was OK to preserve existing behavior) E.g., But my use case aside: is there any way to check for an unset or empty array? |
At the moment we don't have an index that can serve a query that's filtering by array equality. The index we build to accelerate This is definitely a reasonable feature request. Here's a possible workaround you can use: include a schema generation number on each row, and filter with that.
(note that null < 1) |
We are adding a new attribute that contains a filterable array of strings, but we want backwards compatibility with old data that does not have this set yet. So my thinking was to leverage a filter of the form
[x, 'Eq', null]
or[x, 'Eq' []]
. Alas neither seems to work:filter error in key
x: type mismatch, Eq expects array filter operator, but got null
or
filter error in key
x: type mismatch, Eq expects array filter operator, but got []
Please let me know if there is a better way to approach this, thanks!
The text was updated successfully, but these errors were encountered: