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
86538b33
Commit
86538b33
authored
May 18, 2005
by
ramil@mysql.com
Browse files
Options
Browse Files
Download
Plain Diff
Merge rkalimullin@bk-internal.mysql.com:/home/bk/mysql-5.0
into mysql.com:/home/ram/work/5.0.b6267
parents
c1b512fa
d85e052d
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
10 additions
and
12 deletions
+10
-12
mysql-test/r/system_mysql_db.result
mysql-test/r/system_mysql_db.result
+2
-2
mysql-test/r/type_enum.result
mysql-test/r/type_enum.result
+3
-3
mysql-test/r/type_ranges.result
mysql-test/r/type_ranges.result
+2
-2
sql/sql_insert.cc
sql/sql_insert.cc
+2
-1
sql/sql_parse.cc
sql/sql_parse.cc
+1
-4
No files found.
mysql-test/r/system_mysql_db.result
View file @
86538b33
...
...
@@ -116,7 +116,7 @@ func CREATE TABLE `func` (
`name` char(64) collate utf8_bin NOT NULL default '',
`ret` tinyint(1) NOT NULL default '0',
`dl` char(128) collate utf8_bin NOT NULL default '',
`type` enum('function','aggregate') character set utf8 NOT NULL
default 'function'
,
`type` enum('function','aggregate') character set utf8 NOT NULL,
PRIMARY KEY (`name`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_bin COMMENT='User defined functions'
show create table tables_priv;
...
...
@@ -164,7 +164,7 @@ Table Create Table
proc CREATE TABLE `proc` (
`db` char(64) character set latin1 collate latin1_bin NOT NULL default '',
`name` char(64) NOT NULL default '',
`type` enum('FUNCTION','PROCEDURE') NOT NULL
default 'FUNCTION'
,
`type` enum('FUNCTION','PROCEDURE') NOT NULL,
`specific_name` char(64) NOT NULL default '',
`language` enum('SQL') NOT NULL default 'SQL',
`sql_data_access` enum('CONTAINS_SQL','NO_SQL','READS_SQL_DATA','MODIFIES_SQL_DATA') NOT NULL default 'CONTAINS_SQL',
...
...
mysql-test/r/type_enum.result
View file @
86538b33
...
...
@@ -1626,7 +1626,7 @@ create table t1 (a enum (' ','a','b') not null);
show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`a` enum('','a','b') NOT NULL
default ''
`a` enum('','a','b') NOT NULL
) ENGINE=MyISAM DEFAULT CHARSET=latin1
drop table t1;
create table t1 (a enum (' ','a','b ') not null default 'b ');
...
...
@@ -1670,12 +1670,12 @@ show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`a` int(11) default '1',
`b` enum('value','_value','') NOT NULL
default 'value'
`b` enum('value','_value','') NOT NULL
) ENGINE=MyISAM DEFAULT CHARSET=latin1
show columns from t1;
Field Type Null Key Default Extra
a int(11) YES 1
b enum('value','_value','') NO
value
b enum('value','_value','') NO
drop table t1;
CREATE TABLE t1 (c enum('a', 'A') BINARY);
INSERT INTO t1 VALUES ('a'),('A');
...
...
mysql-test/r/type_ranges.result
View file @
86538b33
...
...
@@ -62,7 +62,7 @@ blob_col blob NULL YES NULL #
tinyblob_col tinyblob NULL YES NULL #
mediumblob_col mediumblob NULL NO #
longblob_col longblob NULL NO #
options enum('one','two','tree') latin1_swedish_ci NO MUL
one
#
options enum('one','two','tree') latin1_swedish_ci NO MUL #
flags set('one','two','tree') latin1_swedish_ci NO #
show keys from t1;
Table Non_unique Key_name Seq_in_index Column_name Collation Cardinality Sub_part Packed Null Index_type Comment
...
...
@@ -231,7 +231,7 @@ date_time datetime NULL YES NULL #
new_blob_col varchar(20) latin1_swedish_ci YES NULL #
tinyblob_col tinyblob NULL YES NULL #
mediumblob_col mediumblob NULL NO #
options enum('one','two','tree') latin1_swedish_ci NO MUL
one
#
options enum('one','two','tree') latin1_swedish_ci NO MUL #
flags set('one','two','tree') latin1_swedish_ci NO #
new_field char(10) latin1_swedish_ci NO new #
show full columns from t2;
...
...
sql/sql_insert.cc
View file @
86538b33
...
...
@@ -965,7 +965,8 @@ int check_that_all_fields_are_given_values(THD *thd, TABLE *entry)
for
(
Field
**
field
=
entry
->
field
;
*
field
;
field
++
)
{
if
((
*
field
)
->
query_id
!=
thd
->
query_id
&&
((
*
field
)
->
flags
&
NO_DEFAULT_VALUE_FLAG
))
((
*
field
)
->
flags
&
NO_DEFAULT_VALUE_FLAG
)
&&
((
*
field
)
->
real_type
()
!=
FIELD_TYPE_ENUM
))
{
push_warning_printf
(
thd
,
MYSQL_ERROR
::
WARN_LEVEL_WARN
,
ER_NO_DEFAULT_FOR_FIELD
,
...
...
sql/sql_parse.cc
View file @
86538b33
...
...
@@ -5432,12 +5432,9 @@ new_create_field(THD *thd, char *field_name, enum_field_types type,
new_field
->
comment
=*
comment
;
/*
Set flag if this field doesn't have a default value
Enum values has always the first value as a default (set in
make_empty_rec().
*/
if
(
!
default_value
&&
!
(
type_modifier
&
AUTO_INCREMENT_FLAG
)
&&
(
type_modifier
&
NOT_NULL_FLAG
)
&&
type
!=
FIELD_TYPE_TIMESTAMP
&&
type
!=
FIELD_TYPE_ENUM
)
(
type_modifier
&
NOT_NULL_FLAG
)
&&
type
!=
FIELD_TYPE_TIMESTAMP
)
new_field
->
flags
|=
NO_DEFAULT_VALUE_FLAG
;
if
(
length
&&
!
(
new_field
->
length
=
(
uint
)
atoi
(
length
)))
...
...
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