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

[Bug]: sql_mode no_auto_value_on_zero is not implemented #16227

Open
1 task done
fengttt opened this issue May 17, 2024 · 1 comment
Open
1 task done

[Bug]: sql_mode no_auto_value_on_zero is not implemented #16227

fengttt opened this issue May 17, 2024 · 1 comment
Assignees
Labels
kind/bug Something isn't working severity/s1 High impact: Logical errors or data errors that must occur
Milestone

Comments

@fengttt
Copy link
Contributor

fengttt commented May 17, 2024

Is there an existing issue for the same bug?

  • I have checked the existing issues.

Branch Name

main

Commit ID

62bc77f

Other Environment Information

- Hardware parameters:
- OS type:
- Others:

Actual Behavior

Even though this is documented, but we did not implement it.

So we will need to decide if we should implement this feature. This feature itself is more like a misfeature. So I am not sure.

But in the mean time, we need to update document.

Expected Behavior

No response

Steps to Reproduce

create table tt(i int not null auto_increment primary key, j int);

insert into tt values (1, 2);
insert into tt values (null, 3); -- correct

mysql> select * from tt;
+------+------+
| i    | j    |
+------+------+
|    1 |    2 |
|    2 |    3 |
+------+------+
2 rows in set (0.00 sec)


mysql> insert into tt values (0, 4); -- bug
Query OK, 1 row affected (0.01 sec)

mysql> select * from tt;
+------+------+
| i    | j    |
+------+------+
|    1 |    2 |
|    2 |    3 |
|    0 |    4 |
+------+------+
3 rows in set (0.00 sec)

Additional information

mysql> select @@sql_mode;
+-----------------------------------------------------------------------------------------------------------------------+
| @@sql_mode |
+-----------------------------------------------------------------------------------------------------------------------+
| ERROR_FOR_DIVISION_BY_ZERO,NO_ENGINE_SUBSTITUTION,NO_ZERO_DATE,NO_ZERO_IN_DATE,ONLY_FULL_GROUP_BY,STRICT_TRANS_TABLES |
+-----------------------------------------------------------------------------------------------------------------------+

@fengttt fengttt added kind/bug Something isn't working needs-triage labels May 17, 2024
@matrix-meow matrix-meow added this to the 1.2.0 milestone May 17, 2024
@sukki37 sukki37 modified the milestones: 1.2.0, 1.2.1 May 18, 2024
@dengn
Copy link
Contributor

dengn commented May 20, 2024

For documentation side, it's already updated in the lastest version.
https://docs.matrixorigin.cn/dev/MatrixOne/Reference/Variable/system-variables/sql-mode/

It will be default as 1.2.0 will be released.

@sukki37 sukki37 added severity/s1 High impact: Logical errors or data errors that must occur and removed needs-triage labels May 20, 2024
@sukki37 sukki37 assigned daviszhen and unassigned matrix-meow May 20, 2024
@daviszhen daviszhen assigned ck89119 and unassigned daviszhen May 22, 2024
@aressu1985 aressu1985 modified the milestones: 1.2.1, 1.3.0 May 30, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/bug Something isn't working severity/s1 High impact: Logical errors or data errors that must occur
Projects
None yet
Development

No branches or pull requests

7 participants