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
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
mariadb
Commits
0b6a7865
Commit
0b6a7865
authored
Apr 26, 2002
by
monty@hundin.mysql.fi
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Don't change FLOAT(X+1,X) to FLOAT(X+2,X)
parent
64234373
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
37 additions
and
3 deletions
+37
-3
Docs/manual.texi
Docs/manual.texi
+5
-1
mysql-test/r/show_check.result
mysql-test/r/show_check.result
+16
-0
mysql-test/t/show_check.test
mysql-test/t/show_check.test
+14
-0
sql/sql_parse.cc
sql/sql_parse.cc
+2
-2
No files found.
Docs/manual.texi
View file @
0b6a7865
...
...
@@ -46857,7 +46857,7 @@ users use this code as the rest of the code and because of this we are
not yet 100% confident in this code.
@menu
* News-3.23.51::
* News-3.23.51::
Changes in release 3.23.51
* News-3.23.50:: Changes in release 3.23.50
* News-3.23.49:: Changes in release 3.23.49
* News-3.23.48:: Changes in release 3.23.48
...
...
@@ -46915,6 +46915,10 @@ not yet 100% confident in this code.
@node News-3.23.51, News-3.23.50, News-3.23.x, News-3.23.x
@appendixsubsec Changes in release 3.23.51
@itemize @bullet
@item
Fixed the @code{FLOAT(X+1,X)} is not converted to @code{FLOAT(X+2,X)}.
(This also affected @code{DECIMAL}, @code{DOUBLE} and @code{REAL} types)
@item
Fixed the result from @code{IF()} is case in-sensitive if the 2 and
third arguments are case sensitive.
@end itemize
mysql-test/r/show_check.result
View file @
0b6a7865
...
...
@@ -92,3 +92,19 @@ t1 CREATE TABLE `t1` (
`a` int(11) NOT NULL default '0',
PRIMARY KEY (`a`)
) TYPE=MyISAM
Field Type Null Key Default Extra
a decimal(9,2) YES NULL
b decimal(9,0) YES NULL
e double(9,2) YES NULL
f double(5,0) YES NULL
h float(3,2) YES NULL
i float(3,0) YES NULL
Field Type Null Key Default Extra
c decimal(10,0) YES NULL
d double YES NULL
f float YES NULL
r double YES NULL
Field Type Null Key Default Extra
c decimal(4,3) YES NULL
d double(4,3) YES NULL
f float(4,3) YES NULL
mysql-test/t/show_check.test
View file @
0b6a7865
...
...
@@ -73,3 +73,17 @@ drop table t1;
create
table
t1
(
a
int
not
null
,
primary
key
(
a
));
show
create
table
t1
;
drop
table
t1
;
create
table
t1
(
a
decimal
(
9
,
2
),
b
decimal
(
9
,
0
),
e
double
(
9
,
2
),
f
double
(
5
,
0
),
h
float
(
3
,
2
),
i
float
(
3
,
0
));
show
columns
from
t1
;
drop
table
t1
;
# Check auto conversions of types
create
table
t1
(
c
decimal
,
d
double
,
f
float
,
r
real
);
show
columns
from
t1
;
drop
table
t1
;
create
table
t1
(
c
decimal
(
3
,
3
),
d
double
(
3
,
3
),
f
float
(
3
,
3
));
show
columns
from
t1
;
drop
table
t1
;
sql/sql_parse.cc
View file @
0b6a7865
...
...
@@ -2432,9 +2432,9 @@ bool add_field_to_list(char *field_name, enum_field_types type,
uint
sign_len
=
type_modifier
&
UNSIGNED_FLAG
?
0
:
1
;
if
(
new_field
->
length
&&
new_field
->
decimals
&&
new_field
->
length
<
new_field
->
decimals
+
2
&&
new_field
->
length
<
new_field
->
decimals
+
1
&&
new_field
->
decimals
!=
NOT_FIXED_DEC
)
new_field
->
length
=
new_field
->
decimals
+
2
;
/* purecov: inspected */
new_field
->
length
=
new_field
->
decimals
+
1
;
/* purecov: inspected */
switch
(
type
)
{
case
FIELD_TYPE_TINY
:
...
...
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