Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Related concerns around spec description of IS NULL and IS NOT NULL #644

Open
philvarner opened this issue Oct 26, 2021 · 4 comments
Open

Comments

@philvarner
Copy link
Contributor

I'm looking at: https://github.com/opengeospatial/ogcapi-features/blob/master/cql2/standard/clause_6_basic_cql2.adoc

Few related concerns:

  1. This doesn't mention "IS NOT NULL" as allowed as an operator, but used in an example for IS NULL.
  2. I assume "NOT IS NULL" would also work, but this isn't mentioned.
  3. There's no example using just "IS NULL"
  4. Is there a CQL JSON Operator "isNotNull" also?
@pvretano
Copy link
Contributor

pvretano commented Oct 26, 2021

@philvarner Requirement 1 says that a basic CQL2 implementation must support the BNF production booleanValueExpression which includes the production comaprisonPredicate which includes the production isNullPredicate which includes both is null and is not null expressions.

booleanValueExpression = andExpression
                       | orExpression
                       | notExpression
                       | comparisonPredicate
                       | spatialPredicate
                       | temporalPredicate
                       | arrayPredicate
                       | subExpression;

comparisonPredicate = binaryComparisonPredicate
                    | isLikePredicate
                    | isBetweenPredicate
                    | isInListPredicate
                    | isNullPredicate;

isNullPredicate = scalarExpression "IS" ["NOT"] "NULL";

I'm guessing that is not sufficient explanation so I'll add a few more words into the text ... and examples.

@philvarner
Copy link
Contributor Author

ah, great. What about

Is there a CQL JSON Operator "isNotNull" also?

?

@pvretano
Copy link
Contributor

pvretano commented Oct 27, 2021

@philvarner, yes. There is a not operator and an isNull operator in JSON as well so you can combine them to get not null. Again, examples would help and I will add some.

@jerstlouis
Copy link
Member

jerstlouis commented Jun 28, 2022

@philvarner

Regarding:

  1. I assume "NOT IS NULL" would also work, but this isn't mentioned.

My understanding is that this is not supported by cql2-text.

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants