Skip to content
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

[YCQL] Support for tuples #936

Open
frozenspider opened this issue Mar 6, 2019 · 0 comments
Open

[YCQL] Support for tuples #936

frozenspider opened this issue Mar 6, 2019 · 0 comments
Assignees
Labels
area/ycql Yugabyte CQL (YCQL) kind/enhancement This is an enhancement of an existing feature priority/medium Medium priority issue
Projects

Comments

@frozenspider
Copy link
Contributor

frozenspider commented Mar 6, 2019

Jira Link: DB-4693
Right now, tuple is not even a reserved name and is treated as a missing UDT:

cqlsh> CREATE TABLE k.test(k int PRIMARY KEY, t tuple<int, text>);
SyntaxException: Query error: Invalid SQL Statement. syntax error, unexpected '<', expecting ')'
CREATE TABLE k.test(k int PRIMARY KEY, t tuple<int, text>);
                                              ^
 (error -11)

cqlsh> CREATE TABLE k.test(k int PRIMARY KEY, t tuple);
InvalidRequest: Error from server: code=2200 [Invalid query] message="Query error: Type Not Found. Could not find user defined type
CREATE TABLE k.test(k int PRIMARY KEY, t tuple);
                                         ^^^^^
 (error -311)"
@kmuthukk kmuthukk added the kind/enhancement This is an enhancement of an existing feature label Mar 6, 2019
@kmuthukk kmuthukk added this to To Do in YCQL via automation Mar 6, 2019
yugabyte-ci pushed a commit that referenced this issue Mar 18, 2019
Summary:
TUPLE made into a keyword, the same way LIST/SET/MAP are.
Using it triggers Feature Not Supported error.

Here's the result:

```
cqlsh> CREATE TABLE k.test(p INT PRIMARY KEY , tu tuple);
SyntaxException: Query error: Invalid SQL Statement. syntax error, unexpected ')', expecting '<'
CREATE TABLE k.test(p INT PRIMARY KEY , tu tuple);
                                                ^
 (error -11)

cqlsh> CREATE TABLE k.test(p INT PRIMARY KEY , tu tuple<>);
SyntaxException: Query error: Invalid SQL Statement. syntax error, unexpected NOT_EQUALS, expecting '<'
CREATE TABLE k.test(p INT PRIMARY KEY , tu tuple<>);
                                                ^^
 (error -11)

cqlsh> CREATE TABLE k.test(p INT PRIMARY KEY , tu tuple< >);
SyntaxException: Query error: Invalid SQL Statement. syntax error, unexpected '>'
CREATE TABLE k.test(p INT PRIMARY KEY , tu tuple< >);
                                                  ^
 (error -11)

cqlsh> CREATE TABLE k.test(p INT PRIMARY KEY , tu tuple<int>);
SyntaxException: Query error: Feature Not Supported
CREATE TABLE k.test(p INT PRIMARY KEY , tu tuple<int>);
                                           ^^^^^
 (error -14)

cqlsh> CREATE TABLE k.test(p INT PRIMARY KEY , tu tuple<int,int>);
SyntaxException: Query error: Feature Not Supported
CREATE TABLE k.test(p INT PRIMARY KEY , tu tuple<int,int>);
                                           ^^^^^
 (error -14)

cqlsh> CREATE TABLE k.test(p INT PRIMARY KEY , tu tuple<int1,int2>);
SyntaxException: Query error: Feature Not Supported
CREATE TABLE k.test(p INT PRIMARY KEY , tu tuple<int1,int2>);
                                           ^^^^^
 (error -14)
```

Test Plan:
None, tested placeholder manually.
Proper test will be added in #936

Reviewers: mihnea, bogdan, robert, kannan, oleg, neil

Reviewed By: neil

Subscribers: oleg, yql

Differential Revision: https://phabricator.dev.yugabyte.com/D6327
@rthallamko3 rthallamko3 added the area/ycql Yugabyte CQL (YCQL) label Dec 29, 2022
@yugabyte-ci yugabyte-ci added the priority/medium Medium priority issue label Dec 29, 2022
@yugabyte-ci yugabyte-ci added status/awaiting-triage Issue awaiting triage and removed status/awaiting-triage Issue awaiting triage labels Jan 17, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/ycql Yugabyte CQL (YCQL) kind/enhancement This is an enhancement of an existing feature priority/medium Medium priority issue
Projects
YCQL
  
To Do
Status: No status
Development

No branches or pull requests

5 participants