Skip to content

Conversation

@Alnen
Copy link
Contributor

@Alnen Alnen commented Jan 25, 2024

Changelog entry

...

Changelog category

  • New feature

Additional information

...

@Alnen Alnen requested a review from a team as a code owner January 25, 2024 15:37
@github-actions
Copy link

github-actions bot commented Jan 25, 2024

2024-01-25 15:41:17 UTC Pre-commit check for 9818507 has started.
2024-01-25 15:41:19 UTC Build linux-x86_64-relwithdebinfo is running...
🟢 2024-01-25 16:22:05 UTC Build successful.
2024-01-25 16:22:14 UTC Tests are running...
🟢 2024-01-25 18:00:30 UTC Tests successful.

Test history

TESTS PASSED ERRORS FAILED SKIPPED MUTED?
60009 50735 0 0 9247 27

@github-actions
Copy link

github-actions bot commented Jan 25, 2024

2024-01-25 15:50:18 UTC Pre-commit check for 9818507 has started.
2024-01-25 15:50:20 UTC Build linux-x86_64-release-asan is running...
🟢 2024-01-25 16:30:04 UTC Build successful.
2024-01-25 16:30:15 UTC Tests are running...
🔴 2024-01-25 18:02:03 UTC Some tests failed, follow the links below.

Test history

TESTS PASSED ERRORS FAILED SKIPPED MUTED?
15945 15840 0 15 57 33

object_type_ref: an_id_or_type;

create_table_stmt: CREATE (TABLE | TABLESTORE | EXTERNAL TABLE) (IF NOT EXISTS)? simple_table_ref LPAREN create_table_entry (COMMA create_table_entry)* COMMA? RPAREN
create_table_stmt: CREATE (TABLE | TABLESTORE | EXTERNAL TABLE) (IF NOT EXISTS | OR REPLACE)? simple_table_ref LPAREN create_table_entry (COMMA create_table_entry)* COMMA? RPAREN
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

As I remember, we wanted syntax like CREATE [OR REPLACE] EXTERNAL TABLE ..., but here in this rule I see another syntax: CREATE EXTERNAL TABLE [OR REPLACE] .... I think that the first option is more proper from the point of view of the natural language

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed

namespace NObjectOptionsParsing {
Y_HAS_MEMBER(ExistingOk); // for create
Y_HAS_MEMBER(MissingOk); // for drop
Y_HAS_MEMBER(IsReplace); // for create
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ReplaceIfExists. This is creation operation

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed

optional string Location = 6;
repeated TColumnDescription Columns = 7;
optional bytes Content = 8;
optional bool IsReplace = 9;
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ReplaceIfExists.
But it has no sense for describe operation. Is it OK? Maybe we need different protos for describe and create operations?
At least comment for this field is required.

std::map<TString, TDeferredAtom>&& features, const TObjectOperatorContext& context);
TNodePtr BuildCreateObjectOperation(TPosition pos, const TString& objectId, const TString& typeId,
bool existingOk, std::map<TString, TDeferredAtom>&& features, const TObjectOperatorContext& context);
bool existingOk, bool isReplace, std::map<TString, TDeferredAtom>&& features, const TObjectOperatorContext& context);
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

replaceIfExists

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed

std::set<TString> FeaturesToReset;
protected:
bool ExistingOk = false;
bool IsReplace = false;
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ReplaceIfExists

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed


TFuture<TGenericResult> CreateExternalTable(const TString& cluster, const TCreateExternalTableSettings& settings,
bool createDir, bool existingOk) override
bool createDir, bool existingOk, bool isReplace) override
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

replaceIfExists

}

TFuture<TGenericResult> CreateTable(NYql::TKikimrTableMetadataPtr metadata, bool createDir, bool existingOk) override {
TFuture<TGenericResult> CreateTable(NYql::TKikimrTableMetadataPtr metadata, bool createDir, bool existingOk, bool isReplace) override {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

replaceIfExists

TFuture<TGenericResult> CreateExternalTable(const TString& cluster,
const NYql::TCreateExternalTableSettings& settings,
bool createDir, bool existingOk) override {
bool createDir, bool existingOk, bool isReplace) override {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

replaceIfExists


void FillCreateExternalTableColumnDesc(NKikimrSchemeOp::TExternalTableDescription& externalTableDesc,
const TString& name,
bool isReplace,
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

replaceIfExists


void FillCreateExternalTableColumnDesc(NKikimrSchemeOp::TExternalTableDescription& externalTableDesc,
const TString& name,
bool isReplace,
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

replaceIfExists

@github-actions
Copy link

github-actions bot commented Jan 29, 2024

2024-01-29 13:51:19 UTC Pre-commit check for a842f79 has started.
2024-01-29 13:51:22 UTC Build linux-x86_64-relwithdebinfo is running...
🔴 2024-01-29 14:28:45 UTC Build failed. see the build logs.
2024-01-29 14:29:02 UTC Tests are running...
🔴 2024-01-29 14:49:29 UTC Test run completed, no test results found for commit c95fc8d. Please check build logs.
2024-01-29 14:49:33 UTC Check cancelled

@github-actions
Copy link

github-actions bot commented Jan 29, 2024

2024-01-29 13:51:45 UTC Pre-commit check for a842f79 has started.
2024-01-29 13:51:47 UTC Build linux-x86_64-release-asan is running...
🔴 2024-01-29 14:31:52 UTC Build failed. see the build logs.
2024-01-29 14:32:05 UTC Tests are running...
🔴 2024-01-29 14:47:36 UTC Some tests failed, follow the links below.

Test history

TESTS PASSED ERRORS FAILED SKIPPED MUTED?
7474 7196 0 266 2 10

@github-actions
Copy link

github-actions bot commented Jan 29, 2024

2024-01-29 14:51:36 UTC Pre-commit check for ffe33a5 has started.
2024-01-29 14:51:38 UTC Build linux-x86_64-relwithdebinfo is running...
🟢 2024-01-29 14:59:39 UTC Build successful.
2024-01-29 14:59:55 UTC Tests are running...
🔴 2024-01-29 16:42:29 UTC Some tests failed, follow the links below.

Test history

TESTS PASSED ERRORS FAILED SKIPPED MUTED?
60232 50940 0 3 9254 35

@github-actions
Copy link

github-actions bot commented Jan 29, 2024

2024-01-29 14:51:44 UTC Pre-commit check for ffe33a5 has started.
2024-01-29 14:51:47 UTC Build linux-x86_64-release-asan is running...
🟢 2024-01-29 15:00:18 UTC Build successful.
2024-01-29 15:00:33 UTC Tests are running...
🔴 2024-01-29 16:40:08 UTC Some tests failed, follow the links below.

Test history

TESTS PASSED ERRORS FAILED SKIPPED MUTED?
15984 15878 0 20 55 31

optional string Location = 6;
repeated TColumnDescription Columns = 7;
optional bytes Content = 8;
optional bool ReplaceIfExists = 9;
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This field has no sense for describe operation. It's worth to write comment about it.

Visit(msg.GetBlock3());
Visit(msg.GetRule_simple_table_ref4());
Visit(msg.GetToken5());
Visit(msg.GetBlock4());
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We need to add tests for this new behaviour to ydb/library/yql/sql/v1/format/sql_format_ut.cpp

@github-actions
Copy link

github-actions bot commented Jan 30, 2024

2024-01-30 08:21:27 UTC Pre-commit check for 513f53f has started.
2024-01-30 08:21:30 UTC Build linux-x86_64-relwithdebinfo is running...
🟢 2024-01-30 09:01:16 UTC Build successful.
2024-01-30 09:01:29 UTC Tests are running...
🟢 2024-01-30 10:44:17 UTC Tests successful.

Test history

TESTS PASSED ERRORS FAILED SKIPPED MUTED?
60250 50967 0 0 9254 29

@github-actions
Copy link

github-actions bot commented Jan 30, 2024

2024-01-30 08:21:30 UTC Pre-commit check for 513f53f has started.
2024-01-30 08:21:33 UTC Build linux-x86_64-release-asan is running...
🟢 2024-01-30 09:00:52 UTC Build successful.
2024-01-30 09:01:04 UTC Tests are running...
🔴 2024-01-30 10:36:41 UTC Some tests failed, follow the links below.

Test history

TESTS PASSED ERRORS FAILED SKIPPED MUTED?
16008 15897 0 25 63 23

Copy link
Collaborator

@nepal nepal left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

sql part lgtm

@starlinskiy starlinskiy mentioned this pull request Feb 12, 2024
@vitstn vitstn mentioned this pull request Feb 16, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants