You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I did not yet think about this one in deep yet not in all search engines something like null does exists, example some even don't allow to send null and require to send nothing instead.
I'm not even yet sure if I for example indexing multi values like in the test example "tags": ["Tag A", "Tag B"] and should be even possible with a null via "tags": ["Tag A", null, "Tag C"], its sure more technical not a real world example.
But maybe something like a IsEmptyCondition make sense. This would be keep in mind that "title": "" and "title": null at the end would be the same. And Empty would on multi values only match when it is [].
The text was updated successfully, but these errors were encountered:
alexander-schranz
changed the title
Add Support for IsNullCondition or IsEmptyCondition
[Core] Add Support for IsNullCondition or IsEmptyCondition
Dec 15, 2023
I'm not even yet sure if I for example indexing multi values like in the test example "tags": ["Tag A", "Tag B"] and should be even possible with a null via "tags": ["Tag A", null, "Tag C"], its sure more technical not a real world example.
What would even be the merit in having having null in a list like that (even if it's technically possible). In the real world, what would it mean to have a null in a list? For non-associative arrays I'm not sure what the added value would be. Think more realistic use cases would be tags: null, tags: [], tags: [{key: value, key2: value2}, {key: value, key2: null}] (associative).
But maybe something like a IsEmptyCondition make sense. This would be keep in mind that "title": "" and "title": null at the end would be the same. And Empty would on multi values only match when it is [].
I'm not sure how others perceive this, but to me title: "" and title: null are two different things. Having title: "" means the title has a value and is set to "", while with title: null it has no value (maybe it was not set, missing, or not available at that time). If IsEmptyCondition would handle both "" and null, you will no longer distuingish between the two of them. Think a IsNullCondition that explicetly only handles null values would be my preference and let IsEmptyCondition handle the rest.
Like you already said, some engines probably don't allow null, so I don't know how that would be handled (maybe engines that allow null can use the IsNullCondition, and others should use IsEmptyCondition for those cases).
I did not yet think about this one in deep yet not in all search engines something like
null
does exists, example some even don't allow to send null and require to send nothing instead.I'm not even yet sure if I for example indexing multi values like in the test example
"tags": ["Tag A", "Tag B"]
and should be even possible with a null via"tags": ["Tag A", null, "Tag C"]
, its sure more technical not a real world example.But maybe something like a
IsEmptyCondition
make sense. This would be keep in mind that"title": ""
and"title": null
at the end would be the same. And Empty would on multi values only match when it is[]
.The text was updated successfully, but these errors were encountered: