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

Violation of the not-null constraint for adding column #94

Closed
tangenta opened this issue May 12, 2022 · 0 comments · Fixed by #96
Closed

Violation of the not-null constraint for adding column #94

tangenta opened this issue May 12, 2022 · 0 comments · Fixed by #96
Labels
bug Something isn't working

Comments

@tangenta
Copy link
Owner

Bug Report

Please answer these questions before submitting your issue. Thanks!

1. Minimal reproduce step (Required)

drop table if exists t;
create table t (a tinyint);
insert into t set a = 10 ;
alter table t add column b int not null, change column a c char(5) first;
select * from t;

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

+------+---+
| c    | b |
+------+---+
| 10   | 0 |
+------+---+

3. What did you see instead (Required)

+------+---+
| c    | b |
+------+---+
| 10   | NULL |
+------+---+

4. What is your TiDB version? (Required)

405d2c0

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant