diff options
author | unknown <monty@mysql.com> | 2004-12-07 15:47:00 +0200 |
---|---|---|
committer | unknown <monty@mysql.com> | 2004-12-07 15:47:00 +0200 |
commit | 5b3b9e78a4791385fea782ed2b0e6ffdadb15cb9 (patch) | |
tree | b1c918186908fb490aa860c35dc9e2154aa633c8 /sql/sql_show.cc | |
parent | 916dab97c41b21cab922a69a6b65a1695f92388d (diff) | |
download | mariadb-git-5b3b9e78a4791385fea782ed2b0e6ffdadb15cb9.tar.gz |
Update results for new varchar handling
Fixed compiler warnings
String results in CREATE ... SELECT are now created as CHAR(0), VARCHAR(X) or TEXT() depending on item->max_length
myisam/myisampack.c:
Indentation cleanup
mysql-test/r/analyse.result:
Update results for new varchar handling
mysql-test/r/case.result:
Update results for new varchar handling
mysql-test/r/cast.result:
Update results for new varchar handling
mysql-test/r/create.result:
Update results for new varchar handling
mysql-test/r/ctype_mb.result:
Update results for new varchar handling
mysql-test/r/ctype_ucs.result:
Update results for new varchar handling
mysql-test/r/ctype_utf8.result:
Update results for new varchar handling
mysql-test/r/func_group.result:
Update results for new varchar handling
mysql-test/r/func_str.result:
Update results for new varchar handling
mysql-test/r/func_system.result:
Update results for new varchar handling
mysql-test/r/heap.result:
Update results for new varchar handling
mysql-test/r/heap_hash.result:
Update results for new varchar handling
mysql-test/r/information_schema.result:
Update results for new varchar handling
mysql-test/r/metadata.result:
Update results for new varchar handling
mysql-test/r/null.result:
Update results for new varchar handling
mysql-test/r/ps_2myisam.result:
Update results for new varchar handling
mysql-test/r/ps_3innodb.result:
Update results for new varchar handling
mysql-test/r/ps_4heap.result:
Update results for new varchar handling
mysql-test/r/ps_5merge.result:
Update results for new varchar handling
mysql-test/r/ps_6bdb.result:
Update results for new varchar handling
mysql-test/r/subselect.result:
Update results for new varchar handling
mysql-test/r/type_ranges.result:
Update results for new varchar handling
mysql-test/r/union.result:
Update results for new varchar handling
mysql-test/t/heap.test:
Update results for new varchar handling
mysql-test/t/type_ranges.test:
Added extra test to test generated type for string functions
sql/field.cc:
Update results for new varchar handling
sql/field.h:
Update results for new varchar handling
We have to use orig_table instead of table as 'table' may point to a new field in the created table
sql/field_conv.cc:
Update results for new varchar handling
sql/ha_heap.cc:
Indentation fixes
sql/ha_innodb.cc:
Update results for new varchar handling
sql/item.cc:
Update results for new varchar handling
Remove compiler warnings
String results in CREATE ... SELECT are now created as CHAR(0), VARCHAR(X) or TEXT() depending on item->max_length
sql/item.h:
Update results for new varchar handling
sql/item_func.cc:
Update results for new varchar handling
String results in CREATE ... SELECT are now created as CHAR(0), VARCHAR(X) or TEXT() depending on item->max_length
sql/item_func.h:
ANALYZE now return VARCHAR columns
sql/procedure.h:
Update results for new varchar handling
sql/sql_acl.cc:
After merge fixes
sql/sql_select.cc:
Update results for new varchar handling
String results in temporary tables are now created as CHAR(0), VARCHAR(X) or TEXT() depending on item->max_length
sql/sql_show.cc:
After merge fixes
sql/sql_table.cc:
After merge fixes
strings/ctype-tis620.c:
After merge fixes
tests/client_test.c:
Fixed results, as in MySQL 5.0 strings in CREATE ... SELECT are creates VARCHAR columns
Diffstat (limited to 'sql/sql_show.cc')
-rw-r--r-- | sql/sql_show.cc | 22 |
1 files changed, 10 insertions, 12 deletions
diff --git a/sql/sql_show.cc b/sql/sql_show.cc index f30eeb2d206..7acbe564f58 100644 --- a/sql/sql_show.cc +++ b/sql/sql_show.cc @@ -1859,9 +1859,10 @@ bool uses_only_table_name_fields(Item *item, TABLE_LIST *table) Item **child; Item **item_end= (item_func->arguments()) + item_func->argument_count(); for (child= item_func->arguments(); child != item_end; child++) + { if (!uses_only_table_name_fields(*child, table)) return 0; - return 1; + } } else if (item->type() == Item::FIELD_ITEM) { @@ -1871,19 +1872,16 @@ bool uses_only_table_name_fields(Item *item, TABLE_LIST *table) ST_FIELD_INFO *field_info= schema_table->fields_info; const char *field_name1= field_info[schema_table->idx_field1].field_name; const char *field_name2= field_info[schema_table->idx_field2].field_name; - if(table->table != item_field->field->table || - (cs->coll->strnncollsp(cs, (uchar *) field_name1, strlen(field_name1), - (uchar *) item_field->field_name, - strlen(item_field->field_name)) && - cs->coll->strnncollsp(cs, (uchar *) field_name2, strlen(field_name2), - (uchar *) item_field->field_name, - strlen(item_field->field_name)))) + if (table->table != item_field->field->table || + (cs->coll->strnncollsp(cs, (uchar *) field_name1, strlen(field_name1), + (uchar *) item_field->field_name, + strlen(item_field->field_name), 0) && + cs->coll->strnncollsp(cs, (uchar *) field_name2, strlen(field_name2), + (uchar *) item_field->field_name, + strlen(item_field->field_name), 0))) return 0; - else - return 1; } - else - return 1; + return 1; } |