List:Internals« Previous MessageNext Message »
From:gluh Date:June 16 2005 8:27am
Subject:bk commit into 5.0 tree (gluh:1.1947) BUG#9434
View as plain text  
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
  1.1947 05/06/16 13:27:22 gluh@stripped +3 -0
  Fix for bug#9434 SHOW CREATE DATABASE `information_schema`;
    added ability to do SHOW CREATE DATABASE `information_schema`

  sql/sql_show.cc
    1.252 05/06/16 13:27:17 gluh@stripped +22 -15
    Fix for bug#9434 SHOW CREATE DATABASE `information_schema`;
      added ability to do SHOW CREATE DATABASE `information_schema`

  mysql-test/t/information_schema.test
    1.40 05/06/16 13:27:17 gluh@stripped +5 -0
    Fix for bug#9434 SHOW CREATE DATABASE `information_schema`;
      added ability to do SHOW CREATE DATABASE `information_schema`

  mysql-test/r/information_schema.result
    1.57 05/06/16 13:27:17 gluh@stripped +3 -0
    Fix for bug#9434 SHOW CREATE DATABASE `information_schema`;
      added ability to do SHOW CREATE DATABASE `information_schema`

# 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.intranet.mysql.r18.ru
# Root:	/home/gluh/MySQL/Merge/5.0

--- 1.251/sql/sql_show.cc	Thu Jun 16 12:11:48 2005
+++ 1.252/sql/sql_show.cc	Thu Jun 16 13:27:17 2005
@@ -448,25 +448,32 @@
     DBUG_RETURN(TRUE);
   }
 #endif
-
-  (void) sprintf(path,"%s/%s",mysql_data_home, dbname);
-  length=unpack_dirname(path,path);		// Convert if not unix
-  found_libchar= 0;
-  if (length && path[length-1] == FN_LIBCHAR)
+  if (!my_strcasecmp(system_charset_info, dbname,
+                     information_schema_name.str))
   {
-    found_libchar= 1;
-    path[length-1]=0;				// remove ending '\'
+    dbname= information_schema_name.str;
+    create.default_table_charset= system_charset_info;
   }
-  if (access(path,F_OK))
+  else
   {
-    my_error(ER_BAD_DB_ERROR, MYF(0), dbname);
-    DBUG_RETURN(TRUE);
+    (void) sprintf(path,"%s/%s",mysql_data_home, dbname);
+    length=unpack_dirname(path,path);		// Convert if not unix
+    found_libchar= 0;
+    if (length && path[length-1] == FN_LIBCHAR)
+    {
+      found_libchar= 1;
+      path[length-1]=0;				// remove ending '\'
+    }
+    if (access(path,F_OK))
+    {
+      my_error(ER_BAD_DB_ERROR, MYF(0), dbname);
+      DBUG_RETURN(TRUE);
+    }
+    if (found_libchar)
+      path[length-1]= FN_LIBCHAR;
+    strmov(path+length, MY_DB_OPT_FILE);
+    load_db_opt(thd, path, &create);
   }
-  if (found_libchar)
-    path[length-1]= FN_LIBCHAR;
-  strmov(path+length, MY_DB_OPT_FILE);
-  load_db_opt(thd, path, &create);
-
   List<Item> field_list;
   field_list.push_back(new Item_empty_string("Database",NAME_LEN));
   field_list.push_back(new Item_empty_string("Create Database",1024));

--- 1.56/mysql-test/r/information_schema.result	Thu Jun 16 12:11:47 2005
+++ 1.57/mysql-test/r/information_schema.result	Thu Jun 16 13:27:17 2005
@@ -832,3 +832,6 @@
 CONTAINS SQL
 drop procedure p1;
 drop procedure p2;
+show create database information_schema;
+Database	Create Database
+information_schema	CREATE DATABASE `information_schema` /*!40100 DEFAULT CHARACTER SET utf8 */

--- 1.39/mysql-test/t/information_schema.test	Thu Jun 16 12:11:48 2005
+++ 1.40/mysql-test/t/information_schema.test	Thu Jun 16 13:27:17 2005
@@ -552,3 +552,8 @@
 where specific_name like 'p%';
 drop procedure p1;
 drop procedure p2;
+
+#
+# Bug #9434 SHOW CREATE DATABASE information_schema;
+#
+show create database information_schema;
Thread
bk commit into 5.0 tree (gluh:1.1947) BUG#9434gluh16 Jun