[MDEV-29647] ROW_NUMBER is not 0 for warnings in case without row in view Created: 2022-09-27  Updated: 2023-11-28

Status: Open
Project: MariaDB Server
Component/s: None
Affects Version/s: 10.7, 10.8, 10.9, 10.10, 10.11
Fix Version/s: 10.11

Type: Bug Priority: Major
Reporter: Lena Startseva Assignee: Oleksandr Byelkin
Resolution: Unresolved Votes: 0
Labels: view-protocol

Issue Links:
PartOf
is part of MDEV-27691 make working view-protocol Open
Relates
relates to MDEV-28651 quote(NULL) returns incorrect result ... Closed

 Description   

In MDEV-26635 was changed behavior for ROW_NUMBER, but in view we still get 1 instead 0:
Test:

create view v1 as SELECT CAST('.00000000000000000000000000000000000001e111111111111111111111' AS DECIMAL(38,0)) AS a;
select * from v1;
drop view v1;

Expected result:

a
99999999999999999999999999999999999999
Warnings:
Warning	1916	Got overflow when converting '' to DECIMAL. Value truncated
Warning	1292	Truncated incorrect DECIMAL value: '.00000000000000000000000000000000000001e111111111111111111111'
Warning	1264	Out of range value for column 'a' at row 0

Actual result:

a
99999999999999999999999999999999999999
Warnings:
Warning	1916	Got overflow when converting '' to DECIMAL. Value truncated
Warning	1292	Truncated incorrect DECIMAL value: '.00000000000000000000000000000000000001e111111111111111111111'
Warning	1264	Out of range value for column 'a' at row 1


Generated at Thu Feb 08 10:10:13 UTC 2024 using Jira 8.20.16#820016-sha1:9d11dbea5f4be3d4cc21f03a88dd11d8c8687422.