Skip to content

Enum data type as a synonim for Enum8 or Enum16.#5886

Merged
alexey-milovidov merged 7 commits intoClickHouse:masterfrom
dimarub2000:master
Jul 5, 2019
Merged

Enum data type as a synonim for Enum8 or Enum16.#5886
alexey-milovidov merged 7 commits intoClickHouse:masterfrom
dimarub2000:master

Conversation

@dimarub2000
Copy link
Contributor

I hereby agree to the terms of the CLA available at: https://yandex.ru/legal/cla/?lang=en

Category (leave one):

  • New Feature

Short description (up to few sentences):
Added Enum data type as a synonim for Enum8 or Enum16.

Copy link
Member

@alexey-milovidov alexey-milovidov left a comment

Choose a reason for hiding this comment

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

.

SELECT CAST(x, 'Int16') FROM t_enum16;
SELECT toTypeName(CAST('a', 'Enum(\'a\' = 2, \'b\' = 128)'));
SELECT toTypeName(CAST('a', 'Enum(\'a\' = 2, \'b\' = 127)'));

Copy link
Member

Choose a reason for hiding this comment

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

DROP TABLE at end.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Done


template <typename DataTypeEnum>
static DataTypePtr create(const ASTPtr & arguments)
static DataTypePtr createExect(const ASTPtr & arguments)
Copy link
Member

Choose a reason for hiding this comment

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

createExact?

@alexey-milovidov alexey-milovidov merged commit f25a3fd into ClickHouse:master Jul 5, 2019
@abyss7 abyss7 added the pr-feature Pull request with new product feature label Jul 11, 2019
@BayoNet BayoNet mentioned this pull request Aug 9, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

pr-feature Pull request with new product feature

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants