Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
M
MariaDB
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
nexedi
MariaDB
Commits
7c4aa334
Commit
7c4aa334
authored
May 19, 2005
by
unknown
Browse files
Options
Browse Files
Download
Plain Diff
Merge rkalimullin@bk-internal.mysql.com:/home/bk/mysql-5.0
into mysql.com:/usr/home/ram/work/5.0.b6961
parents
675ed25f
e8792fba
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
18 additions
and
9 deletions
+18
-9
mysql-test/r/strict.result
mysql-test/r/strict.result
+2
-4
mysql-test/t/strict.test
mysql-test/t/strict.test
+2
-2
sql/field.cc
sql/field.cc
+14
-3
No files found.
mysql-test/r/strict.result
View file @
7c4aa334
...
...
@@ -770,7 +770,7 @@ ERROR 22003: Out of range value adjusted for column 'col1' at row 1
INSERT INTO t1 VALUES ('-100E+1');
ERROR 22003: Out of range value adjusted for column 'col1' at row 1
INSERT INTO t1 VALUES ('-100E');
ERROR
22003: Out of range value adjusted
for column 'col1' at row 1
ERROR
HY000: Incorrect decimal value: '-100E'
for column 'col1' at row 1
UPDATE t1 SET col1 =col1 * 50000 WHERE col1 =11;
ERROR 22003: Out of range value adjusted for column 'col1' at row 6
UPDATE t1 SET col1 =col1 / 0 WHERE col1 > 0;
...
...
@@ -782,8 +782,7 @@ ERROR HY000: Incorrect decimal value: '' for column 'col1' at row 1
INSERT INTO t1 (col1) VALUES ('a59b');
ERROR HY000: Incorrect decimal value: 'a59b' for column 'col1' at row 1
INSERT INTO t1 (col1) VALUES ('1a');
Warnings:
Note 1265 Data truncated for column 'col1' at row 1
ERROR HY000: Incorrect decimal value: '1a' for column 'col1' at row 1
INSERT IGNORE INTO t1 (col1) VALUES ('2a');
Warnings:
Note 1265 Data truncated for column 'col1' at row 1
...
...
@@ -818,7 +817,6 @@ NULL
-10.56
11.00
10.00
1.00
2.00
NULL
99.99
...
...
mysql-test/t/strict.test
View file @
7c4aa334
...
...
@@ -740,7 +740,7 @@ INSERT INTO t1 VALUES ('-101.55');
INSERT
INTO
t1
VALUES
(
'-1010.55'
);
--
error
1264
INSERT
INTO
t1
VALUES
(
'-100E+1'
);
--
error
1
264
--
error
1
366
INSERT
INTO
t1
VALUES
(
'-100E'
);
--
error
1264
UPDATE
t1
SET
col1
=
col1
*
50000
WHERE
col1
=
11
;
...
...
@@ -754,7 +754,7 @@ INSERT INTO t1 (col1) VALUES ('');
#--error 1265
--
error
1366
INSERT
INTO
t1
(
col1
)
VALUES
(
'a59b'
);
#--error 1265
--
error
1366
INSERT
INTO
t1
(
col1
)
VALUES
(
'1a'
);
INSERT
IGNORE
INTO
t1
(
col1
)
VALUES
(
'2a'
);
INSERT
IGNORE
INTO
t1
values
(
1
/
0
);
...
...
sql/field.cc
View file @
7c4aa334
...
...
@@ -2365,9 +2365,20 @@ int Field_new_decimal::store(const char *from, uint length,
my_decimal
decimal_value
;
DBUG_ENTER
(
"Field_new_decimal::store(char*)"
);
switch
((
err
=
str2my_decimal
(
E_DEC_FATAL_ERROR
&
if
((
err
=
str2my_decimal
(
E_DEC_FATAL_ERROR
&
~
(
E_DEC_OVERFLOW
|
E_DEC_BAD_NUM
),
from
,
length
,
charset
,
&
decimal_value
)))
{
from
,
length
,
charset
,
&
decimal_value
))
&&
table
->
in_use
->
abort_on_warning
)
{
push_warning_printf
(
table
->
in_use
,
MYSQL_ERROR
::
WARN_LEVEL_ERROR
,
ER_TRUNCATED_WRONG_VALUE_FOR_FIELD
,
ER
(
ER_TRUNCATED_WRONG_VALUE_FOR_FIELD
),
"decimal"
,
from
,
field_name
,
(
ulong
)
table
->
in_use
->
row_count
);
DBUG_RETURN
(
err
);
}
switch
(
err
)
{
case
E_DEC_TRUNCATED
:
set_warning
(
MYSQL_ERROR
::
WARN_LEVEL_NOTE
,
WARN_DATA_TRUNCATED
,
1
);
break
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment