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

Support renaming a field in Delta Lake #18163

Closed
findinpath opened this issue Jul 7, 2023 · 1 comment
Closed

Support renaming a field in Delta Lake #18163

findinpath opened this issue Jul 7, 2023 · 1 comment
Labels
delta-lake Delta Lake connector

Comments

@findinpath
Copy link
Contributor

For Delta Lake tables with column mapping mode set to id or name Trino should support renaming nested fields

Relates to #12638

The SQL parser needs to be extended as well to support referencing nested fields when doing such operations

trino> alter table delta.tiny.test3 rename column b.c to crenamed;
Query 20230707_045702_00018_v7kmf failed: line 1:45: mismatched input '.'. Expecting: 'TO'
io.trino.sql.parser.ParsingException: line 1:45: mismatched input '.'. Expecting: 'TO'
	at io.trino.sql.parser.ErrorHandler.syntaxError(ErrorHandler.java:109)
	at org.antlr.v4.runtime.ProxyErrorListener.syntaxError(ProxyErrorListener.java:41)
	at org.antlr.v4.runtime.Parser.notifyErrorListeners(Parser.java:544)
	at org.antlr.v4.runtime.DefaultErrorStrategy.reportInputMismatch(DefaultErrorStrategy.java:327)
	at org.antlr.v4.runtime.DefaultErrorStrategy.reportError(DefaultErrorStrategy.java:139)
	at io.trino.sql.parser.SqlBaseParser.statement(SqlBaseParser.java:5501)

PoC for dropping nested fields via DROP COLUMN #16002

@findinpath findinpath added the delta-lake Delta Lake connector label Jul 7, 2023
@ebyhr
Copy link
Member

ebyhr commented Jul 7, 2023

Closing as duplicate of #18097

@ebyhr ebyhr closed this as completed Jul 7, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
delta-lake Delta Lake connector
Development

No branches or pull requests

2 participants