diff options
author | unknown <bell@sanja.is.com.ua> | 2003-10-24 17:28:32 +0300 |
---|---|---|
committer | unknown <bell@sanja.is.com.ua> | 2003-10-24 17:28:32 +0300 |
commit | ce2c46ddd6676960e0c002aa83c7913e85ebdc47 (patch) | |
tree | 63bd3fb6c3566519729c8f88b30bbb74d936361e /sql/item_func.h | |
parent | 5ee2807c4907d14fd97278e665b69717d3920226 (diff) | |
download | mariadb-git-ce2c46ddd6676960e0c002aa83c7913e85ebdc47.tar.gz |
support 'parallel' updates and rallback of whole statement in case of error in evalueting value which should be assigned
(BUG#1484)
mysql-test/r/variables.result:
test of swaping variables
mysql-test/t/variables.test:
test of swaping variables
sql/item_func.cc:
new method of user variables to pre-fetch value
sql/item_func.h:
new method of user variables to pre-fetch value
sql/set_var.cc:
check() methods fetch & store value
sql/set_var.h:
check() methods fetch & store value
Diffstat (limited to 'sql/item_func.h')
-rw-r--r-- | sql/item_func.h | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/sql/item_func.h b/sql/item_func.h index 8086e65786d..fe9c2645216 100644 --- a/sql/item_func.h +++ b/sql/item_func.h @@ -900,6 +900,14 @@ class Item_func_set_user_var :public Item_func user_var_entry *entry; char buffer[MAX_FIELD_WIDTH]; String value; + union + { + longlong vint; + double vreal; + String *vstr; + } save_result; + String save_buff; + public: Item_func_set_user_var(LEX_STRING a,Item *b) @@ -910,6 +918,7 @@ public: String *val_str(String *str); bool update_hash(void *ptr, uint length, enum Item_result type, CHARSET_INFO *cs, Derivation dv); + bool check(); bool update(); enum Item_result result_type () const { return cached_result_type; } bool fix_fields(THD *thd, struct st_table_list *tables, Item **ref); |