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]: insert ignore values reported error Inconsistent with MySQL behavior #15345

Open
1 task done
heni02 opened this issue Apr 7, 2024 · 27 comments
Open
1 task done
Assignees
Labels
bvt error occurred during bvt test kind/bug Something isn't working long-term-job phase/testing severity/s0 Extreme impact: Cause the application to break down and seriously affect the use
Milestone

Comments

@heni02
Copy link
Contributor

heni02 commented Apr 7, 2024

Is there an existing issue for the same bug?

  • I have checked the existing issues.

Branch Name

main

Commit ID

85734e6

Other Environment Information

- Hardware parameters:
- OS type:
- Others:

Actual Behavior

mo insert ignore values目前和mysql差异:
1: null约束报错,mysql不报错
企业微信截图_83957d89-7354-420b-b17d-f3023d0376a4
企业微信截图_50f89551-2692-4e43-b636-fc713798da9e

2.外键约束报错,mysql不报错
企业微信截图_51c6b1e0-5286-4230-94ad-896bd9223c23

3.超出类型值范围报错,mysql不报错
企业微信截图_8b145678-3969-40fb-ad09-63b84bc716be

4.类型不匹配报错,mysql不报错
企业微信截图_c0b33fd2-9f98-4b63-9abc-c46272eaa612

Expected Behavior

No response

Steps to Reproduce

1.
create table insert_ignore_04 (product_id INT NOT NULL AUTO_INCREMENT,product_name VARCHAR(255) NOT NULL,quantity_in_stock INT DEFAULT 0,price DECIMAL(10, 2) NOT NULL,PRIMARY KEY (product_id));
insert ignore into insert_ignore_04(product_name, price) VALUES('Laptop', 1200.00),('Monitor', 150.00),('Keyboard', NULL),('Mouse', 15.00);
insert ignore into insert_ignore_04(product_name, quantity_in_stock,price) VALUES(NULL, 5,1200.00),('board',6, NULL),('phone',NULL,1500.00);
select * from insert_ignore_04;

2.
create table parent_table(parent_id INT AUTO_INCREMENT PRIMARY KEY,parent_name VARCHAR(255) NOT NULL);
create table child_table(child_id INT AUTO_INCREMENT PRIMARY KEY,child_name VARCHAR(255) NOT NULL,parent_id INT,FOREIGN KEY (parent_id) REFERENCES parent_table(parent_id)
);
insert ignore into parent_table (parent_name) VALUES ('Parent 1'), ('Parent 2'), ('Parent 3');
insert ignore into child_table (child_name, parent_id) VALUES('Child 1', 1),('Child 2', 2),('Child 3', 4),('Child 4', 1);

3.
create table insert_ignore_02(c1 int,c2 decimal(6,2),unique key(c1));
insert ignore into insert_ignore_02 values("abc",1234.56);

4.
create table insert_ignore_05(id TINYINT,created_at DATETIME);
insert ignore INTO insert_ignore_05 (id, created_at) VALUES(130, '2024-04-03 10:00:00'),(-129, '2024-04-03 11:00:00'),(100, '2024-04-03 12:00:00');

Additional information

No response

@heni02 heni02 added kind/bug Something isn't working needs-triage severity/s0 Extreme impact: Cause the application to break down and seriously affect the use labels Apr 7, 2024
@heni02 heni02 added this to the 1.2.0 milestone Apr 7, 2024
@ouyuanning ouyuanning modified the milestones: 1.2.0, 1.3.0-Backlog Apr 7, 2024
@heni02 heni02 added bvt error occurred during bvt test and removed needs-triage labels Apr 7, 2024
@ouyuanning
Copy link
Contributor

语法不一致的部分暂不做处理

2 similar comments
@ouyuanning
Copy link
Contributor

语法不一致的部分暂不做处理

@ouyuanning
Copy link
Contributor

语法不一致的部分暂不做处理

@ouyuanning ouyuanning assigned jensenojs and unassigned ouyuanning Apr 24, 2024
@ouyuanning
Copy link
Contributor

锦赛统一处理吧。
近期先只处理性能问题就好了。语法的问题,可以留到后面的版本再处理

@jensenojs
Copy link
Contributor

insert ignore需要重新实现

@jensenojs
Copy link
Contributor

同上

1 similar comment
@jensenojs
Copy link
Contributor

同上

@jensenojs
Copy link
Contributor

暂无进展

@jensenojs
Copy link
Contributor

同上

@jensenojs
Copy link
Contributor

同上

@jensenojs
Copy link
Contributor

等重新设计方案

@jensenojs
Copy link
Contributor

处理 moc#3351

@jensenojs
Copy link
Contributor

无进展

@jensenojs
Copy link
Contributor

no process

@jensenojs
Copy link
Contributor

同上

1 similar comment
@jensenojs
Copy link
Contributor

同上

@jensenojs
Copy link
Contributor

处理中移物联的insert pprof

@sukki37 sukki37 removed this from the 1.3.0-Backlog milestone Jul 3, 2024
@sukki37 sukki37 added this to the 1.3.0 milestone Jul 3, 2024
@jensenojs
Copy link
Contributor

处理中移物联的insert pprof

@jensenojs
Copy link
Contributor

等on duplicate update的方案

@jensenojs
Copy link
Contributor

等on dup的解决方案

@jensenojs
Copy link
Contributor

not working on it

1 similar comment
@jensenojs
Copy link
Contributor

not working on it

@jensenojs jensenojs assigned aunjgr and unassigned jensenojs Jul 23, 2024
@aunjgr
Copy link
Contributor

aunjgr commented Jul 25, 2024

#17500 完成后再看

@aunjgr
Copy link
Contributor

aunjgr commented Jul 31, 2024

not working on it today

@aunjgr
Copy link
Contributor

aunjgr commented Aug 6, 2024

#17500 完成后再看

@sukki37 sukki37 modified the milestones: 2.0.0, 2.1.0 Oct 20, 2024
@aunjgr
Copy link
Contributor

aunjgr commented Oct 31, 2024

@heni02 case有问题。

create table insert_ignore_02(c1 int,c2 decimal(6,2),unique key(c1));
insert ignore into insert_ignore_02 values("abc",1234.56);

int列给了一个字符串值"abc"

@aunjgr aunjgr assigned heni02 and unassigned aunjgr Nov 6, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bvt error occurred during bvt test kind/bug Something isn't working long-term-job phase/testing severity/s0 Extreme impact: Cause the application to break down and seriously affect the use
Projects
None yet
Development

No branches or pull requests

6 participants