diff options
author | Marko Mäkelä <marko.makela@mariadb.com> | 2021-06-08 15:02:40 +0300 |
---|---|---|
committer | Marko Mäkelä <marko.makela@mariadb.com> | 2021-06-08 15:02:40 +0300 |
commit | 72b248962136ccb08800d8267522549f0cdd4647 (patch) | |
tree | 1dbb0f39d6543b3b33cd395f9513140c6a6b0694 /sql/item.h | |
parent | bb28bffc3ed179a9912aced2b873e43999111887 (diff) | |
parent | 6e9642beb2cafecbcb96e591e1b4466b877d4885 (diff) | |
download | mariadb-git-72b248962136ccb08800d8267522549f0cdd4647.tar.gz |
Merge 10.3 into 10.4
Diffstat (limited to 'sql/item.h')
-rw-r--r-- | sql/item.h | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/sql/item.h b/sql/item.h index dbd2cb0b1df..5a530f97192 100644 --- a/sql/item.h +++ b/sql/item.h @@ -3521,7 +3521,7 @@ public: bool check_table_name_processor(void *arg) { Check_table_name_prm &p= *(Check_table_name_prm *) arg; - if (p.table_name.length && table_name) + if (!field && p.table_name.length && table_name) { DBUG_ASSERT(p.db.length); if ((db_name && @@ -5857,7 +5857,10 @@ public: table_map used_tables() const; void update_used_tables(); table_map not_null_tables() const; - bool const_item() const { return used_tables() == 0; } + bool const_item() const + { + return (*ref)->const_item() && (null_ref_table == NO_NULL_TABLE); + } TABLE *get_null_ref_table() const { return null_ref_table; } bool walk(Item_processor processor, bool walk_subquery, void *arg) { |