diff options
author | bell@sanja.is.com.ua <> | 2003-11-02 16:56:39 +0200 |
---|---|---|
committer | bell@sanja.is.com.ua <> | 2003-11-02 16:56:39 +0200 |
commit | 74ddfaaddae303b6d6a3d8a3468eb48b900f7165 (patch) | |
tree | d846d489c4b8544d16e284703116d76f00e95390 /sql/item.cc | |
parent | 42fb7d1c07687335ac085c393c33cae3d3d17370 (diff) | |
download | mariadb-git-74ddfaaddae303b6d6a3d8a3468eb48b900f7165.tar.gz |
after review fix
Diffstat (limited to 'sql/item.cc')
-rw-r--r-- | sql/item.cc | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/sql/item.cc b/sql/item.cc index 9caea3cee4c..e1373cee41f 100644 --- a/sql/item.cc +++ b/sql/item.cc @@ -872,13 +872,16 @@ bool Item_field::fix_fields(THD *thd, TABLE_LIST *tables, Item **ref) else if (tmp == not_found_field && refer == (Item **)not_found_item) { if (upward_lookup) + { // We can't say exactly what absend table or field my_printf_error(ER_BAD_FIELD_ERROR, ER(ER_BAD_FIELD_ERROR), MYF(0), full_name(), thd->where); + } else + { // Call to report error find_field_in_tables(thd, this, tables, &where, 1); - + } return -1; } else if (refer != (Item **)not_found_item) @@ -1468,15 +1471,19 @@ bool Item_ref::fix_fields(THD *thd,TABLE_LIST *tables, Item **reference) else if (ref == (Item **)not_found_item && tmp == not_found_field) { if (upward_lookup) + { // We can't say exactly what absend (table or field) my_printf_error(ER_BAD_FIELD_ERROR, ER(ER_BAD_FIELD_ERROR), MYF(0), full_name(), thd->where); + } else + { // Call to report error find_item_in_list(this, *(thd->lex.current_select->get_item_list()), &counter, REPORT_ALL_ERRORS); + } ref= 0; return 1; } |