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
0df74eae
Commit
0df74eae
authored
Feb 14, 2007
by
ibabaev@bk-internal.mysql.com
Browse files
Options
Browse Files
Download
Plain Diff
Merge bk-internal.mysql.com:/data0/bk/mysql-5.1
into bk-internal.mysql.com:/data0/bk/mysql-5.1-opt
parents
ae27eeea
4aab8494
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
38 additions
and
3 deletions
+38
-3
mysql-test/r/default.result
mysql-test/r/default.result
+11
-1
mysql-test/r/gis.result
mysql-test/r/gis.result
+4
-0
mysql-test/t/default.test
mysql-test/t/default.test
+8
-1
mysql-test/t/gis.test
mysql-test/t/gis.test
+8
-0
sql/item.cc
sql/item.cc
+7
-1
No files found.
mysql-test/r/default.result
View file @
0df74eae
...
@@ -193,6 +193,16 @@ a b c d e f g h i x
...
@@ -193,6 +193,16 @@ a b c d e f g h i x
two large 00:00:05 0007-01-01 11 13 17 0019-01-01 00:00:00 23 1
two large 00:00:05 0007-01-01 11 13 17 0019-01-01 00:00:00 23 1
small 00:00:00 0000-00-00 0 0000-00-00 00:00:00 0 2
small 00:00:00 0000-00-00 0 0000-00-00 00:00:00 0 2
two large 00:00:05 0007-01-01 11 13 17 0019-01-01 00:00:00 23 3
two large 00:00:05 0007-01-01 11 13 17 0019-01-01 00:00:00 23 3
small
00:00:00 0000-00-00 0 0000-00-00 00:00:00 0 4
00:00:00 0000-00-00 0 0000-00-00 00:00:00 0 4
drop table bug20691;
drop table bug20691;
create table t1 (id int not null);
insert into t1 values(default);
Warnings:
Warning 1364 Field 'id' doesn't have a default value
create view v1 (c) as select id from t1;
insert into t1 values(default);
Warnings:
Warning 1364 Field 'id' doesn't have a default value
drop view v1;
drop table t1;
End of 5.0 tests.
End of 5.0 tests.
mysql-test/r/gis.result
View file @
0df74eae
...
@@ -718,6 +718,10 @@ desc t1;
...
@@ -718,6 +718,10 @@ desc t1;
Field Type Null Key Default Extra
Field Type Null Key Default Extra
GeomFromText('point(1 1)') geometry NO
GeomFromText('point(1 1)') geometry NO
drop table t1;
drop table t1;
create table t1 (g geometry not null);
insert into t1 values(default);
ERROR 22003: Cannot get geometry object from data you send to the GEOMETRY field
drop table t1;
create table t1 (f1 tinyint(1), f2 char(1), f3 varchar(1), f4 geometry, f5 datetime);
create table t1 (f1 tinyint(1), f2 char(1), f3 varchar(1), f4 geometry, f5 datetime);
create view v1 as select * from t1;
create view v1 as select * from t1;
desc v1;
desc v1;
...
...
mysql-test/t/default.test
View file @
0df74eae
...
@@ -137,6 +137,13 @@ insert into bug20691 values (DEFAULT, DEFAULT, DEFAULT, DEFAULT, DEFAULT, DEFAUL
...
@@ -137,6 +137,13 @@ insert into bug20691 values (DEFAULT, DEFAULT, DEFAULT, DEFAULT, DEFAULT, DEFAUL
select
*
from
bug20691
order
by
x
asc
;
select
*
from
bug20691
order
by
x
asc
;
drop
table
bug20691
;
drop
table
bug20691
;
###
create
table
t1
(
id
int
not
null
);
insert
into
t1
values
(
default
);
create
view
v1
(
c
)
as
select
id
from
t1
;
insert
into
t1
values
(
default
);
drop
view
v1
;
drop
table
t1
;
--
echo
End
of
5.0
tests
.
--
echo
End
of
5.0
tests
.
mysql-test/t/gis.test
View file @
0df74eae
...
@@ -429,6 +429,14 @@ create table t1 select GeomFromText('point(1 1)');
...
@@ -429,6 +429,14 @@ create table t1 select GeomFromText('point(1 1)');
desc
t1
;
desc
t1
;
drop
table
t1
;
drop
table
t1
;
#
# Bug #20691 (DEFAULT over NOT NULL field)
#
create
table
t1
(
g
geometry
not
null
);
--
error
ER_CANT_CREATE_GEOMETRY_OBJECT
insert
into
t1
values
(
default
);
drop
table
t1
;
#
#
# Bug #11335 View redefines column types
# Bug #11335 View redefines column types
#
#
...
...
sql/item.cc
View file @
0df74eae
...
@@ -5591,6 +5591,13 @@ int Item_default_value::save_in_field(Field *field_arg, bool no_conversions)
...
@@ -5591,6 +5591,13 @@ int Item_default_value::save_in_field(Field *field_arg, bool no_conversions)
{
{
if
(
field_arg
->
flags
&
NO_DEFAULT_VALUE_FLAG
)
if
(
field_arg
->
flags
&
NO_DEFAULT_VALUE_FLAG
)
{
{
if
(
field_arg
->
reset
())
{
my_message
(
ER_CANT_CREATE_GEOMETRY_OBJECT
,
ER
(
ER_CANT_CREATE_GEOMETRY_OBJECT
),
MYF
(
0
));
return
-
1
;
}
if
(
context
->
error_processor
==
&
view_error_processor
)
if
(
context
->
error_processor
==
&
view_error_processor
)
{
{
TABLE_LIST
*
view
=
cached_table
->
top_table
();
TABLE_LIST
*
view
=
cached_table
->
top_table
();
...
@@ -5609,7 +5616,6 @@ int Item_default_value::save_in_field(Field *field_arg, bool no_conversions)
...
@@ -5609,7 +5616,6 @@ int Item_default_value::save_in_field(Field *field_arg, bool no_conversions)
ER
(
ER_NO_DEFAULT_FOR_FIELD
),
ER
(
ER_NO_DEFAULT_FOR_FIELD
),
field_arg
->
field_name
);
field_arg
->
field_name
);
}
}
field_arg
->
set_default
();
return
1
;
return
1
;
}
}
field_arg
->
set_default
();
field_arg
->
set_default
();
...
...
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