Below is the list of changes that have just been committed into a local
5.0 repository of gluh. When gluh does a push these changes will
be propagated to the main repository and, within 24 hours after the
push, to the public repository.
For information on how to access the public repository
see http://dev.mysql.com/doc/mysql/en/installing-source-tree.html
ChangeSet@stripped, 2007-04-18 18:35:22+05:00, gluh@stripped +16 -0
Bug#27747 database metadata doesn't return sufficient column default info
mysql-test/r/alter_table.result@stripped, 2007-04-18 18:35:20+05:00, gluh@stripped +1 -1
result fix
mysql-test/r/create.result@stripped, 2007-04-18 18:35:20+05:00, gluh@stripped +1 -1
result fix
mysql-test/r/ctype_collate.result@stripped, 2007-04-18 18:35:20+05:00, gluh@stripped +1 -1
result fix
mysql-test/r/ctype_recoding.result@stripped, 2007-04-18 18:35:20+05:00, gluh@stripped +3 -3
result fix
mysql-test/r/default.result@stripped, 2007-04-18 18:35:20+05:00, gluh@stripped +1 -1
result fix
mysql-test/r/gis.result@stripped, 2007-04-18 18:35:20+05:00, gluh@stripped +9 -9
result fix
mysql-test/r/information_schema.result@stripped, 2007-04-18 18:35:20+05:00, gluh@stripped +32 -1
result fix
mysql-test/r/key.result@stripped, 2007-04-18 18:35:20+05:00, gluh@stripped +11 -11
result fix
mysql-test/r/mysql.result@stripped, 2007-04-18 18:35:20+05:00, gluh@stripped +2 -2
result fix
mysql-test/r/ps_1general.result@stripped, 2007-04-18 18:35:20+05:00, gluh@stripped +3 -3
result fix
mysql-test/r/show_check.result@stripped, 2007-04-18 18:35:20+05:00, gluh@stripped +1 -1
result fix
mysql-test/r/sp.result@stripped, 2007-04-18 18:35:20+05:00, gluh@stripped +2 -2
result fix
mysql-test/r/type_enum.result@stripped, 2007-04-18 18:35:20+05:00, gluh@stripped +1 -1
result fix
mysql-test/r/type_ranges.result@stripped, 2007-04-18 18:35:20+05:00, gluh@stripped +11 -11
result fix
mysql-test/t/information_schema.test@stripped, 2007-04-18 18:35:20+05:00, gluh@stripped +17 -0
result fix
sql/sql_show.cc@stripped, 2007-04-18 18:35:20+05:00, gluh@stripped +40 -25
Bug#27747 database metadata doesn't return sufficient column default info
# This is a BitKeeper patch. What follows are the unified diffs for the
# set of deltas contained in the patch. The rest of the patch, the part
# that BitKeeper cares about, is below these diffs.
# User: gluh
# Host: eagle.(none)
# Root: /home/gluh/MySQL/Bugs/5.0.27747
--- 1.345/sql/sql_show.cc 2007-03-27 20:34:13 +05:00
+++ 1.346/sql/sql_show.cc 2007-04-18 18:35:20 +05:00
@@ -2652,6 +2652,7 @@ static int get_schema_column_record(THD
String type(tmp,sizeof(tmp), system_charset_info);
char *end;
int decimals, field_length;
+ bool has_now_default, has_default;
if (wild && wild[0] &&
wild_case_compare(system_charset_info, field->field_name,wild))
@@ -2695,33 +2696,47 @@ static int get_schema_column_record(THD
table->field[7]->store(type.ptr(),
(tmp_buff ? tmp_buff - type.ptr() :
type.length()), cs);
- if (show_table->timestamp_field == field &&
- field->unireg_check != Field::TIMESTAMP_UN_FIELD)
- {
- table->field[5]->store(STRING_WITH_LEN("CURRENT_TIMESTAMP"), cs);
- table->field[5]->set_notnull();
- }
- else if (field->unireg_check != Field::NEXT_NUMBER &&
- !field->is_null() &&
- !(field->flags & NO_DEFAULT_VALUE_FLAG))
- {
- String def(tmp1,sizeof(tmp1), cs);
- type.set(tmp, sizeof(tmp), field->charset());
- field->val_str(&type);
- uint dummy_errors;
- def.copy(type.ptr(), type.length(), type.charset(), cs, &dummy_errors);
- table->field[5]->store(def.ptr(), def.length(), def.charset());
- table->field[5]->set_notnull();
- }
- else if (field->unireg_check == Field::NEXT_NUMBER ||
- lex->orig_sql_command != SQLCOM_SHOW_FIELDS ||
- field->maybe_null())
- table->field[5]->set_null(); // Null as default
- else
+
+ has_now_default= (show_table->timestamp_field == field &&
+ field->unireg_check != Field::TIMESTAMP_UN_FIELD);
+
+ has_default= (field->type() != FIELD_TYPE_BLOB &&
+ !(flags & NO_DEFAULT_VALUE_FLAG) &&
+ field->unireg_check != Field::NEXT_NUMBER &&
+ !((thd->variables.sql_mode &
+ (MODE_MYSQL323 | MODE_MYSQL40)) && has_now_default));
+
+ if (has_default)
{
- table->field[5]->store("",0, cs);
- table->field[5]->set_notnull();
+ if (has_now_default)
+ {
+ table->field[5]->store(STRING_WITH_LEN("CURRENT_TIMESTAMP"), cs);
+ table->field[5]->set_notnull();
+ }
+ else if (!field->is_null())
+ {
+ type.set(tmp, sizeof(tmp), field->charset());
+ field->val_str(&type);
+ if (type.length())
+ {
+ String def(tmp1,sizeof(tmp1), cs);
+ uint dummy_errors;
+ /* convert to system_charset_info == utf8 */
+ def.copy(type.ptr(), type.length(), field->charset(),
+ system_charset_info, &dummy_errors);
+ table->field[5]->store(def.ptr(), def.length(), def.charset());
+ table->field[5]->set_notnull();
+ }
+ else
+ {
+ table->field[5]->store("", 0 , cs);
+ table->field[5]->set_notnull();
+ }
+ }
+ else if (field->maybe_null())
+ table->field[5]->set_null();
}
+
pos=(byte*) ((flags & NOT_NULL_FLAG) ? "NO" : "YES");
table->field[6]->store((const char*) pos,
strlen((const char*) pos), cs);
--- 1.31/mysql-test/r/ctype_collate.result 2005-04-11 15:08:58 +05:00
+++ 1.32/mysql-test/r/ctype_collate.result 2007-04-18 18:35:20 +05:00
@@ -488,7 +488,7 @@ t1 CREATE TABLE `t1` (
) ENGINE=MyISAM DEFAULT CHARSET=latin1
SHOW FIELDS FROM t1;
Field Type Null Key Default Extra
-latin1_f char(32) NO
+latin1_f char(32) NO NULL
ALTER TABLE t1 CHANGE latin1_f
latin1_f CHAR(32) CHARACTER SET latin1 COLLATE latin1_bin;
SHOW CREATE TABLE t1;
--- 1.33/mysql-test/r/ctype_recoding.result 2006-10-30 10:13:58 +04:00
+++ 1.34/mysql-test/r/ctype_recoding.result 2007-04-18 18:35:20 +05:00
@@ -54,7 +54,7 @@ Table Create Table
Field Type Null Key Default Extra
SET CHARACTER SET cp1251;
SHOW TABLES;
Tables_in_test
@@ -66,7 +66,7 @@ Table Create Table
Field Type Null Key Default Extra
SET CHARACTER SET utf8;
SHOW TABLES;
Tables_in_test
@@ -78,7 +78,7 @@ Table Create Table
) ENGINE=MyISAM DEFAULT CHARSET=latin1 COMMENT='комментарий таблицы'
SHOW FIELDS FROM таблица;
Field Type Null Key Default Extra
-поле char(32) NO
+поле char(32) NO NULL
SET CHARACTER SET koi8r;
SET CHARACTER SET default;
--- 1.121/mysql-test/r/information_schema.result 2007-03-27 21:31:42 +05:00
+++ 1.122/mysql-test/r/information_schema.result 2007-04-18 18:35:20 +05:00
@@ -990,7 +990,7 @@ b NULL
use test;
show columns from t1;
Field Type Null Key Default Extra
-a int(11) NO
+a int(11) NO NULL
b int(11) YES NULL
drop table t1;
CREATE TABLE t1 (a int);
@@ -1315,3 +1315,34 @@ TABLE_PRIVILEGES information_schema.TABL
TRIGGERS information_schema.TRIGGERS 1
USER_PRIVILEGES information_schema.USER_PRIVILEGES 1
VIEWS information_schema.VIEWS 1
+create table t1 (
+f1 varchar(50),
+f2 varchar(50) not null,
+f3 varchar(50) default '',
+f4 varchar(50) default NULL,
+f5 bigint not null,
+f6 bigint not null default 10,
+f7 datetime not null,
+f8 datetime default '2006-01-01'
+);
+select column_default from information_schema.columns where table_name= 't1';
+column_default
+NULL
+NULL
+
+NULL
+NULL
+10
+NULL
+2006-01-01 00:00:00
+show columns from t1;
+Field Type Null Key Default Extra
+f1 varchar(50) YES NULL
+f2 varchar(50) NO NULL
+f3 varchar(50) YES
+f4 varchar(50) YES NULL
+f5 bigint(20) NO NULL
+f6 bigint(20) NO 10
+f7 datetime NO NULL
+f8 datetime YES 2006-01-01 00:00:00
+drop table t1;
--- 1.90/mysql-test/t/information_schema.test 2007-02-12 16:06:12 +04:00
+++ 1.91/mysql-test/t/information_schema.test 2007-04-18 18:35:20 +05:00
@@ -1023,4 +1023,21 @@ where t.table_schema = 'information_sche
group by c2.column_type order by num limit 1)
group by t.table_name order by num1, t.table_name;
+#
+# Bug#27747 database metadata doesn't return sufficient column default info
+#
+create table t1 (
+ f1 varchar(50),
+ f2 varchar(50) not null,
+ f3 varchar(50) default '',
+ f4 varchar(50) default NULL,
+ f5 bigint not null,
+ f6 bigint not null default 10,
+ f7 datetime not null,
+ f8 datetime default '2006-01-01'
+);
+select column_default from information_schema.columns where table_name= 't1';
+show columns from t1;
+drop table t1;
+
# End of 5.0 tests.
--- 1.54/mysql-test/r/ps_1general.result 2006-08-02 17:48:15 +05:00
+++ 1.55/mysql-test/r/ps_1general.result 2007-04-18 18:35:20 +05:00
@@ -269,7 +269,7 @@ prepare stmt4 from ' show columns from t
SET @arg00="a";
execute stmt4 using @arg00;
Field Type Null Key Default Extra
-a int(11) NO PRI
+a int(11) NO PRI NULL
SET @arg00="b";
execute stmt4 using @arg00;
Field Type Null Key Default Extra
@@ -280,7 +280,7 @@ Field Type Null Key Default Extra
prepare stmt4 from ' show columns from t2 from test like ''a%'' ';
execute stmt4;
Field Type Null Key Default Extra
-a int(11) NO PRI
+a int(11) NO PRI NULL
create index t2_idx on t2(b);
prepare stmt4 from ' show index from t2 from test ';
execute stmt4;
@@ -407,7 +407,7 @@ drop database mysqltest ;
prepare stmt3 from ' describe t2 ';
execute stmt3;
Field Type Null Key Default Extra
-a int(11) NO PRI
+a int(11) NO PRI NULL
b char(10) YES MUL NULL
drop table t2 ;
execute stmt3;
--- 1.63/mysql-test/r/alter_table.result 2007-03-14 13:54:19 +04:00
+++ 1.64/mysql-test/r/alter_table.result 2007-04-18 18:35:20 +05:00
@@ -54,7 +54,7 @@ SHOW FULL COLUMNS FROM t1;
Field Type Collation Null Key Default Extra Privileges Comment
GROUP_ID int(10) unsigned NULL NO PRI 0 #
LANG_ID smallint(5) unsigned NULL NO PRI 0 #
-NAME char(80) latin1_swedish_ci NO MUL #
+NAME char(80) latin1_swedish_ci NO MUL NULL #
DROP TABLE t1;
create table t1 (n int);
insert into t1 values(9),(3),(12),(10);
--- 1.126/mysql-test/r/create.result 2007-04-02 13:50:16 +05:00
+++ 1.127/mysql-test/r/create.result 2007-04-18 18:35:20 +05:00
@@ -430,7 +430,7 @@ d date YES NULL
e varchar(1) NO
f datetime YES NULL
g time YES NULL
-h longblob NO
+h longblob NO NULL
dd time YES NULL
select * from t2;
a b c d e f g h dd
--- 1.35/mysql-test/r/key.result 2006-08-02 17:15:46 +05:00
+++ 1.36/mysql-test/r/key.result 2007-04-18 18:35:20 +05:00
@@ -336,8 +336,8 @@ UNIQUE i1idx (i1),
UNIQUE i2idx (i2));
desc t1;
Field Type Null Key Default Extra
-i1 int(11) NO PRI
-i2 int(11) NO UNI
+i1 int(11) NO PRI NULL
+i2 int(11) NO UNI NULL
show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
@@ -392,25 +392,25 @@ drop table t1;
create table t1 (a int not null primary key, b varchar(20) not null unique);
desc t1;
Field Type Null Key Default Extra
-a int(11) NO PRI
-b varchar(20) NO UNI
+a int(11) NO PRI NULL
+b varchar(20) NO UNI NULL
drop table t1;
create table t1 (a int not null primary key, b int not null unique);
desc t1;
Field Type Null Key Default Extra
-a int(11) NO PRI
-b int(11) NO UNI
+a int(11) NO PRI NULL
+b int(11) NO UNI NULL
drop table t1;
create table t1 (a int not null primary key, b varchar(20) not null, unique (b(10)));
desc t1;
Field Type Null Key Default Extra
-a int(11) NO PRI
-b varchar(20) NO UNI
+a int(11) NO PRI NULL
+b varchar(20) NO UNI NULL
drop table t1;
create table t1 (a int not null primary key, b varchar(20) not null, c varchar(20) not null, unique(b(10),c(10)));
desc t1;
Field Type Null Key Default Extra
-a int(11) NO PRI
-b varchar(20) NO MUL
-c varchar(20) NO
+a int(11) NO PRI NULL
+b varchar(20) NO MUL NULL
+c varchar(20) NO NULL
drop table t1;
--- 1.83/mysql-test/r/show_check.result 2006-11-28 02:47:19 +04:00
+++ 1.84/mysql-test/r/show_check.result 2007-04-18 18:35:20 +05:00
@@ -123,7 +123,7 @@ show full columns from t1;
Field Type Collation Null Key Default Extra Privileges Comment
test_set set('val1','val2','val3') latin1_swedish_ci NO select,insert,update,references
name char(20) latin1_swedish_ci YES O'Brien select,insert,update,references O'Brien as default
-c int(11) NULL NO select,insert,update,references int column
+c int(11) NULL NO NULL select,insert,update,references int column
c-b int(11) NULL YES NULL select,insert,update,references name with a minus
space 2 int(11) NULL YES NULL select,insert,update,references name with a space
drop table t1;
--- 1.29/mysql-test/r/type_enum.result 2007-02-12 17:32:03 +04:00
+++ 1.30/mysql-test/r/type_enum.result 2007-04-18 18:35:20 +05:00
@@ -1675,7 +1675,7 @@ t1 CREATE TABLE `t1` (
show columns from t1;
Field Type Null Key Default Extra
a int(11) YES 1
drop table t1;
CREATE TABLE t1 (c enum('a', 'A') BINARY);
INSERT INTO t1 VALUES ('a'),('A');
--- 1.44/mysql-test/r/type_ranges.result 2006-12-13 13:17:37 +04:00
+++ 1.45/mysql-test/r/type_ranges.result 2007-04-18 18:35:20 +05:00
@@ -63,9 +63,9 @@ time_field time NULL YES NULL #
date_time datetime NULL YES NULL #
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 #
+mediumblob_col mediumblob NULL NO NULL #
+longblob_col longblob NULL NO NULL #
+options enum('one','two','tree') latin1_swedish_ci NO MUL NULL #
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
@@ -218,7 +218,7 @@ Field Type Collation Null Key Default Ex
auto int(5) unsigned NULL NO MUL NULL auto_increment #
string char(10) latin1_swedish_ci YES newdefault #
tiny tinyint(4) NULL NO MUL 0 #
-short smallint(6) NULL NO MUL #
+short smallint(6) NULL NO MUL NULL #
medium mediumint(8) NULL NO MUL 0 #
long_int int(11) NULL NO 0 #
longlong bigint(13) NULL NO MUL 0 #
@@ -235,8 +235,8 @@ time_field time NULL YES NULL #
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 #
+mediumblob_col mediumblob NULL NO NULL #
+options enum('one','two','tree') latin1_swedish_ci NO MUL NULL #
flags set('one','two','tree') latin1_swedish_ci NO #
new_field char(10) latin1_swedish_ci NO new #
show full columns from t2;
@@ -244,7 +244,7 @@ Field Type Collation Null Key Default Ex
auto int(5) unsigned NULL NO 0 #
string char(10) latin1_swedish_ci YES newdefault #
tiny tinyint(4) NULL NO 0 #
-short smallint(6) NULL NO #
+short smallint(6) NULL NO NULL #
medium mediumint(8) NULL NO 0 #
long_int int(11) NULL NO 0 #
longlong bigint(13) NULL NO 0 #
@@ -261,8 +261,8 @@ time_field time NULL YES NULL #
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 #
+mediumblob_col mediumblob NULL NO NULL #
+options enum('one','two','tree') latin1_swedish_ci NO NULL #
flags set('one','two','tree') latin1_swedish_ci NO #
new_field char(10) latin1_swedish_ci NO new #
select t1.auto,t2.auto from t1,t2 where t1.auto=t2.auto and ((t1.string<>t2.string and (t1.string is not null or t2.string is not null)) or (t1.tiny<>t2.tiny and (t1.tiny is not null or t2.tiny is not null)) or (t1.short<>t2.short and (t1.short is not null or t2.short is not null)) or (t1.medium<>t2.medium and (t1.medium is not null or t2.medium is not null)) or (t1.long_int<>t2.long_int and (t1.long_int is not null or t2.long_int is not null)) or (t1.longlong<>t2.longlong and (t1.longlong is not null or t2.longlong is not null)) or (t1.real_float<>t2.real_float and (t1.real_float is not null or t2.real_float is not null)) or (t1.real_double<>t2.real_double and (t1.real_double is not null or t2.real_double is not null)) or (t1.utiny<>t2.utiny and (t1.utiny is not null or t2.utiny is not null)) or (t1.ushort<>t2.ushort and (t1.ushort is not null or t2.ushort is not null)) or (t1.umedium<>t2.umedium and (t1.umedium is not null or t2.umedium is not null)) or (t1.ulong<>t2.ulong
and (t1.ulong is not null or t2.ulong is not null)) or (t1.ulonglong<>t2.ulonglong and (t1.ulonglong is not null or t2.ulonglong is not null)) or (t1.time_stamp<>t2.time_stamp and (t1.time_stamp is not null or t2.time_stamp is not null)) or (t1.date_field<>t2.date_field and (t1.date_field is not null or t2.date_field is not null)) or (t1.time_field<>t2.time_field and (t1.time_field is not null or t2.time_field is not null)) or (t1.date_time<>t2.date_time and (t1.date_time is not null or t2.date_time is not null)) or (t1.new_blob_col<>t2.new_blob_col and (t1.new_blob_col is not null or t2.new_blob_col is not null)) or (t1.tinyblob_col<>t2.tinyblob_col and (t1.tinyblob_col is not null or t2.tinyblob_col is not null)) or (t1.mediumblob_col<>t2.mediumblob_col and (t1.mediumblob_col is not null or t2.mediumblob_col is not null)) or (t1.options<>t2.options and (t1.options is not null or t2.options is not null)) or (t1.flags<>t2.flags and (t1.flags is not null or t2.flags is not n
ull)) or (t1.new_field<>t2.new_field and (t1.new_field is not null or t2.new_field is not null)));
@@ -280,8 +280,8 @@ t1 int(1) NULL NO 0 #
t2 varchar(1) latin1_swedish_ci NO #
t3 varchar(256) latin1_swedish_ci NO #
t4 varbinary(256) NULL NO #
-t5 longtext latin1_swedish_ci NO #
-t6 longblob NULL NO #
+t5 longtext latin1_swedish_ci NO NULL #
+t6 longblob NULL NO NULL #
t7 char(0) latin1_swedish_ci NO #
t8 binary(0) NULL NO #
select t1,t2,length(t3),length(t4),length(t5),length(t6),t7,t8 from t2;
--- 1.27/mysql-test/r/mysql.result 2007-02-19 14:57:02 +04:00
+++ 1.28/mysql-test/r/mysql.result 2007-04-18 18:35:20 +05:00
@@ -91,7 +91,7 @@ i j k
NULL 1 NULL
Field Type Null Key Default Extra
i int(11) YES NULL
-j int(11) NO
+j int(11) NO NULL
k int(11) YES NULL
+------+---+------+
| i | j | k |
@@ -102,7 +102,7 @@ k int(11) YES NULL
| Field | Type | Null | Key | Default | Extra |
+-------+---------+------+-----+---------+-------+
| i | int(11) | YES | | NULL | |
-| j | int(11) | NO | | | |
+| j | int(11) | NO | | NULL | |
| k | int(11) | YES | | NULL | |
+-------+---------+------+-----+---------+-------+
i s1
--- 1.224/mysql-test/r/sp.result 2007-03-27 21:05:14 +05:00
+++ 1.225/mysql-test/r/sp.result 2007-04-18 18:35:20 +05:00
@@ -2463,7 +2463,7 @@ Database (foo)
Level Code Message
Field Type Null Key Default Extra
id char(16) NO
-data int(11) NO
+data int(11) NO NULL
Table Non_unique Key_name Seq_in_index Column_name Collation Cardinality Sub_part Packed Null Index_type Comment
Database Table In_use Name_locked
Privilege Context Comment
@@ -2515,7 +2515,7 @@ Database (foo)
Level Code Message
Field Type Null Key Default Extra
id char(16) NO
-data int(11) NO
+data int(11) NO NULL
Table Non_unique Key_name Seq_in_index Column_name Collation Cardinality Sub_part Packed Null Index_type Comment
Database Table In_use Name_locked
Privilege Context Comment
--- 1.43/mysql-test/r/gis.result 2007-04-02 13:50:35 +05:00
+++ 1.44/mysql-test/r/gis.result 2007-04-18 18:35:20 +05:00
@@ -9,35 +9,35 @@ CREATE TABLE gis_geometrycollection (fi
CREATE TABLE gis_geometry (fid INTEGER NOT NULL PRIMARY KEY, g GEOMETRY);
SHOW FIELDS FROM gis_point;
Field Type Null Key Default Extra
-fid int(11) NO PRI
+fid int(11) NO PRI NULL
g point YES NULL
SHOW FIELDS FROM gis_line;
Field Type Null Key Default Extra
-fid int(11) NO PRI
+fid int(11) NO PRI NULL
g linestring YES NULL
SHOW FIELDS FROM gis_polygon;
Field Type Null Key Default Extra
-fid int(11) NO PRI
+fid int(11) NO PRI NULL
g polygon YES NULL
SHOW FIELDS FROM gis_multi_point;
Field Type Null Key Default Extra
-fid int(11) NO PRI
+fid int(11) NO PRI NULL
g multipoint YES NULL
SHOW FIELDS FROM gis_multi_line;
Field Type Null Key Default Extra
-fid int(11) NO PRI
+fid int(11) NO PRI NULL
g multilinestring YES NULL
SHOW FIELDS FROM gis_multi_polygon;
Field Type Null Key Default Extra
-fid int(11) NO PRI
+fid int(11) NO PRI NULL
g multipolygon YES NULL
SHOW FIELDS FROM gis_geometrycollection;
Field Type Null Key Default Extra
-fid int(11) NO PRI
+fid int(11) NO PRI NULL
g geometrycollection YES NULL
SHOW FIELDS FROM gis_geometry;
Field Type Null Key Default Extra
-fid int(11) NO PRI
+fid int(11) NO PRI NULL
g geometry YES NULL
INSERT INTO gis_point VALUES
(101, PointFromText('POINT(10 10)')),
@@ -430,7 +430,7 @@ mln multilinestring YES NULL
mpg multipolygon YES NULL
gc geometrycollection YES NULL
gm geometry YES NULL
-fid int(11) NO
+fid int(11) NO NULL
DROP TABLE t1;
SELECT AsText(GeometryFromWKB(AsWKB(GeometryFromText('POINT(1 4)'))));
AsText(GeometryFromWKB(AsWKB(GeometryFromText('POINT(1 4)'))))
--- 1.5/mysql-test/r/default.result 2007-02-12 15:41:34 +04:00
+++ 1.6/mysql-test/r/default.result 2007-04-18 18:35:20 +05:00
@@ -115,7 +115,7 @@ Warning 1364 Field 'd' doesn't have a de
desc bug20691;
Field Type Null Key Default Extra
i int(11) YES NULL
-d datetime NO
+d datetime NO NULL
dn datetime NO 0000-00-00 00:00:00
insert into bug20691 values (3, DEFAULT, DEFAULT), (3, '1975-07-10 07:10:03', '1978-01-13 14:08:51'), (3, DEFAULT, DEFAULT);
Warnings:
| Thread |
|---|
| • bk commit into 5.0 tree (gluh:1.2456) BUG#27747 | gluh | 18 Apr |