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

Make the error message of the default value expression more appropriate. #51703

Closed
Tracked by #50936
zimulala opened this issue Mar 12, 2024 · 0 comments · Fixed by #51704
Closed
Tracked by #50936

Make the error message of the default value expression more appropriate. #51703

zimulala opened this issue Mar 12, 2024 · 0 comments · Fixed by #51704
Labels
component/ddl This issue is related to DDL of TiDB. severity/minor type/bug This issue is a bug.

Comments

@zimulala
Copy link
Contributor

Bug Report

Please answer these questions before submitting your issue. Thanks!

1. Minimal reproduce step (Required)

create table t1 (c int(10), c1 varchar(256) default (REPLACE('xdfj-jfj', '-', '')));

Now we support REPLACE as the default value expression, but don't support REPLACE('xdfj-jfj', '-', '')).

2. What did you expect to see? (Required)

Error 3770 (HY000): Default value expression of column 'c1' contains a disallowed function: `REPLACE`.

3. What did you see instead (Required)

Error 3770 (HY000): Default value expression of column 'c1' contains a disallowed function: `REPLACE with disallowed args`.

4. What is your TiDB version? (Required)

master

@zimulala zimulala added type/bug This issue is a bug. severity/minor labels Mar 12, 2024
@zimulala zimulala changed the title Makes the error message of the default value expression more appropriate. Make the error message of the default value expression more appropriate. Mar 12, 2024
ti-chi-bot bot pushed a commit that referenced this issue Mar 12, 2024
@jebter jebter added the component/ddl This issue is related to DDL of TiDB. label May 10, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
component/ddl This issue is related to DDL of TiDB. severity/minor type/bug This issue is a bug.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants