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

Parse MySQL Bit-Value literals #54

Closed
cameronbraid opened this issue May 31, 2023 · 1 comment
Closed

Parse MySQL Bit-Value literals #54

cameronbraid opened this issue May 31, 2023 · 1 comment
Labels
enhancement New feature or request linear

Comments

@cameronbraid
Copy link
Contributor

cameronbraid commented May 31, 2023

See: https://dev.mysql.com/doc/refman/8.0/en/bit-value-literals.html

Describe the problem

The following create table statement fails to be parsed

CREATE TABLE `table` (
            `enabled` bit(1) NOT NULL DEFAULT b'0',
            `lastModified` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6) ON UPDATE CURRENT_TIMESTAMP(6)
)

There are two causes

The statement was generated for a table in percona xtradb 8.0.27-18.1

@cameronbraid cameronbraid added the bug Something isn't working label May 31, 2023
@glittershark
Copy link
Member

Thanks for the great report @cameronbraid! I'm going to split this into two issues (the binary literal issue and the current_timestamp precision issue). I'll repurpose this one for the former.

@glittershark glittershark changed the title unable to parse create table statement Parse MySQL Bit-Value literals May 31, 2023
@glittershark glittershark added enhancement New feature or request and removed bug Something isn't working labels May 31, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request linear
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants