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
cc488e92
Commit
cc488e92
authored
May 11, 2007
by
holyfoot/hf@mysql.com/hfmain.(none)
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
merging fixes
parent
b3ee5e87
Changes
4
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
26 additions
and
10 deletions
+26
-10
mysql-test/t/view.test
mysql-test/t/view.test
+12
-0
sql/item_create.cc
sql/item_create.cc
+2
-1
sql/my_decimal.cc
sql/my_decimal.cc
+11
-0
sql/my_decimal.h
sql/my_decimal.h
+1
-9
No files found.
mysql-test/t/view.test
View file @
cc488e92
...
...
@@ -3213,6 +3213,18 @@ EXPLAIN SELECT * FROM t1 UNION SELECT * FROM v1 ORDER BY a;
DROP
VIEW
v1
;
DROP
TABLE
t1
;
#
# Bug #27921 View ignores precision for CAST()
#
CREATE
VIEW
v1
AS
SELECT
CAST
(
1.23456789
AS
DECIMAL
(
7
,
5
)
)
AS
col
;
SELECT
*
FROM
v1
;
DESCRIBE
v1
;
DROP
VIEW
v1
;
CREATE
VIEW
v1
AS
SELECT
CAST
(
1.23456789
AS
DECIMAL
(
8
,
0
))
AS
col
;
SHOW
CREATE
VIEW
v1
;
DROP
VIEW
v1
;
--
echo
End
of
5.0
tests
.
#
...
...
sql/item_create.cc
View file @
cc488e92
...
...
@@ -3947,6 +3947,7 @@ Create_func_master_pos_wait::create_native(THD *thd, LEX_STRING name,
my_error
(
ER_WRONG_PARAMCOUNT_TO_NATIVE_FCT
,
MYF
(
0
),
name
.
str
);
break
;
}
}
return
func
;
}
...
...
@@ -4972,7 +4973,7 @@ find_qualified_function_builder(THD *thd)
Item
*
create_func_cast
(
Item
*
a
,
Cast_target
cast_type
,
create_func_cast
(
THD
*
thd
,
Item
*
a
,
Cast_target
cast_type
,
const
char
*
c_len
,
const
char
*
c_dec
,
CHARSET_INFO
*
cs
)
{
...
...
sql/my_decimal.cc
View file @
cc488e92
...
...
@@ -208,6 +208,17 @@ my_decimal *date2my_decimal(MYSQL_TIME *ltime, my_decimal *dec)
}
void
my_decimal_trim
(
ulong
*
precision
,
uint
*
scale
)
{
if
(
!
(
*
precision
)
&&
!
(
*
scale
))
{
*
precision
=
10
;
*
scale
=
0
;
return
;
}
}
#ifndef DBUG_OFF
/* routines for debugging print */
...
...
sql/my_decimal.h
View file @
cc488e92
...
...
@@ -395,15 +395,7 @@ int my_decimal_intg(const my_decimal *a)
}
void
my_decimal_trim
(
ulong
*
precision
,
uint
*
scale
)
{
if
(
!
(
*
precision
)
&&
!
(
*
scale
))
{
*
precision
=
10
;
*
scale
=
0
;
return
;
}
}
void
my_decimal_trim
(
ulong
*
precision
,
uint
*
scale
);
#endif
/*my_decimal_h*/
...
...
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