-
Notifications
You must be signed in to change notification settings - Fork 1k
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
Document how to use quoted column names and column aliases #1212
Labels
Comments
Looking at #1212, there may be bugs in this area! |
big-andy-coates
changed the title
Document how to use data that contains field names that are reserved words.
Document how to use column aliases
Apr 26, 2018
big-andy-coates
changed the title
Document how to use column aliases
Document how to use quoted column names and column aliases
Apr 27, 2018
Same issue here, for
|
The backtick approach doesn't work for me - whilst KSQL accepts the
|
Related : #677 |
Closing as there's nothing to document yet, until #677 is fixed |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Users may have data where field names contain reserved words, e.g.
group
. Currently, there is no documentation on how to work with this data with KSQL. Statements such asCREATE STREAM foo (field1 varchar, group varchar ) WITH (KAFKA_TOPIC='foo', VALUE_FORMAT='JSON');
fail with an error due to thegroup
column.I think the work around is to use the backtick character to escape the keyword:
CREATE STREAM foo (field1 varchar, `group` column) WITH (Blah)
And then the user will need to also escape the column name where ever used, e.g.
SELECT `group` FROM foo LIMIT 5;
However, there is no documentation around column aliasing and how to use with keywords. We should fix this.
The text was updated successfully, but these errors were encountered: