You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cassandra.apache.org by "Stefan Miklosovic (Jira)" <ji...@apache.org> on 2025/02/04 14:19:00 UTC
[jira] [Commented] (CASSANDRA-20276) Add not null constraint
[ https://issues.apache.org/jira/browse/CASSANDRA-20276?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17923724#comment-17923724 ]
Stefan Miklosovic commented on CASSANDRA-20276:
-----------------------------------------------
Feel free to take this ticket away from me, I was just curious how easy it will be to build on top of what we have.
I was quit straightforward but what I would like to see is this:
{code}
CREATE TABLE ks.tb (pk int, value int CHECK NOT_NULL, PRIMARY KEY (pk));
{code}
instead of the current
{code}
CREATE TABLE ks.tb (pk int, value int CHECK NOT_NULL(value), PRIMARY KEY (pk));
{code}
It seems like "value" is redundant there, but anyway, does not matter too much if we want to be consistent with everything else. I was looking to Parser.g to model this but it seems to be that in order to bind the name of a column into a constraint, we need to somehow reference it.
> Add not null constraint
> -----------------------
>
> Key: CASSANDRA-20276
> URL: https://issues.apache.org/jira/browse/CASSANDRA-20276
> Project: Apache Cassandra
> Issue Type: Improvement
> Components: Feature/Constraints
> Reporter: Bernardo Botella Corbi
> Assignee: Stefan Miklosovic
> Priority: Normal
> Time Spent: 10m
> Remaining Estimate: 0h
>
> Add a new constraint that checks if a column is null, as defined in CEP-42: https://cwiki.apache.org/confluence/display/CASSANDRA/CEP-42%3A+Constraints+Framework
--
This message was sent by Atlassian Jira
(v8.20.10#820010)
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@cassandra.apache.org
For additional commands, e-mail: commits-help@cassandra.apache.org