- 20 Oct, 2006 2 commits
-
-
dlenev@mockturtle.local authored
into mockturtle.local:/home/dlenev/src/mysql-5.1-bg15228
-
dlenev@mockturtle.local authored
warnings in sql_trigger.cc and sql_view.cc". According to the current version of C++ standard offsetof() macro can't be used for non-POD types. So warnings were emitted when we tried to use this macro for TABLE_LIST and Table_triggers_list classes. Note that despite of these warnings it was probably safe thing to do. This fix tries to circumvent this limitation by implementing custom version of offsetof() macro to be used with these classes. This hack should go away once we will refactor File_parser class. Alternative approaches such as disabling this warning for sql_trigger.cc/sql_view.cc or for the whole server were considered less explicit. Also I was unable to find a way to disable particular warning for particular _part_ of file in GCC.
-
- 19 Oct, 2006 2 commits
-
-
kroki/tomash@moonlight.intranet authored
into moonlight.intranet:/home/tomash/src/mysql_ab/mysql-5.1-bug21856
-
kroki/tomash@moonlight.intranet authored
When statement to be prepared contained CREATE PROCEDURE, CREATE FUNCTION or CREATE TRIGGER statements with a syntax error in it, the preparation would fail with syntax error message, but the memory could be corrupted. The problem occurred because we switch memroot when parse stored routine or trigger definitions, and on parse error we restored the original memroot only after performing some memory operations. In more detail: - prepared statement would activate its own memory root to parse the definition of the stored procedure. - SP would reset this memory root with its own memory root to parse SP statements - a syntax error would happen - prepared statement would restore the original memory root - stored procedure would restore what it thinks was the original memory root, but actually was the statement memory root. That led to double free - in destruction of the statement and in a next call to mysql_parse(). The solution is to restore memroot right after the failed parsing.
-
- 17 Oct, 2006 2 commits
-
-
kroki/tomash@moonlight.intranet authored
into moonlight.intranet:/home/tomash/src/mysql_ab/mysql-5.1-bug21726
-
kroki/tomash@moonlight.intranet authored
into moonlight.intranet:/home/tomash/src/mysql_ab/mysql-5.0-bug21726
-
- 12 Oct, 2006 3 commits
-
-
kroki/tomash@moonlight.intranet authored
-
kroki/tomash@moonlight.intranet authored
into moonlight.intranet:/home/tomash/src/mysql_ab/mysql-5.1-bug20953
-
kroki/tomash@moonlight.intranet authored
should fail to create The problem was that this type of errors was checked during view creation, which doesn't happen when CREATE VIEW is a statement of a created stored routine. The solution is to perform the checks at parse time. The idea of the fix is that the parser checks if a construction just parsed is allowed in current circumstances by testing certain flags, and this flags are reset for VIEWs. The side effect of this change is that if the user already have such bogus routines, it will now get a error when trying to do SHOW CREATE PROCEDURE proc; (and some other) and when trying to execute such routine he will get ERROR 1457 (HY000): Failed to load routine test.p5. The table mysql.proc is missing, corrupt, or contains bad data (internal code -6) However there should be very few such users (if any), and they may (and should) drop these bogus routines.
-
- 10 Oct, 2006 12 commits
-
-
andrey@example.com authored
into example.com:/work/mysql-5.1-runtime
-
andrey@example.com authored
-
kroki/tomash@moonlight.intranet authored
into moonlight.intranet:/home/tomash/src/mysql_ab/mysql-5.1-bug21354
-
andrey@example.com authored
into example.com:/work/mysql-5.1-runtime
-
kroki/tomash@moonlight.intranet authored
into moonlight.intranet:/home/tomash/src/mysql_ab/mysql-5.1-bug21354
-
andrey@example.com authored
This decoupling allows in further versions of MySQL enum interval_type to be reordered without this affecting any backward compatibility in the events code. This changeset doesn't change any exposed behavior but makes events' code more durable to changes outside of their code base. To the reviewer: There is no regression test included as it is impossible to construct one with the current infrastructure which can test it. To test the code one has create and event, then change the order of enum interval_type in my_time.h, update sql/time.cc, recompile the server and run it with scheduler running.
-
kroki/tomash@moonlight.intranet authored
-
kroki/tomash@moonlight.intranet authored
into moonlight.intranet:/home/tomash/src/mysql_ab/mysql-5.1-bug21354
-
kroki/tomash@moonlight.intranet authored
into moonlight.intranet:/home/tomash/src/mysql_ab/mysql-5.0-bug21354
-
kroki/tomash@moonlight.intranet authored
statement. The problem was that during statement re-execution if the result was empty the old result could be returned for group functions. The solution is to implement proper cleanup() method in group functions.
-
kroki/tomash@moonlight.intranet authored
into moonlight.intranet:/home/tomash/src/mysql_ab/mysql-5.1-bug19111
-
kroki/tomash@moonlight.intranet authored
In a trigger or a function used in a statement it is possible to do SELECT from a table being modified by the statement. However, encapsulation of such SELECT into a view and selecting from a view instead of direct SELECT was not possible. This happened because tables used by views (which in their turn were used from functions/triggers) were not excluded from checks in unique_table() routine as it happens for the rest of tables added to the statement table list for prelocking. With this fix we ignore all such tables in unique_table(), thus providing consistency: inside a trigger or a functions SELECT from a view may be used where plain SELECT is allowed. Modification of the same table from function or trigger is still disallowed. Also, this patch doesn't affect the case where SELECT from the table being modified is done outside of function of trigger, such SELECTs are still disallowed (this limitation and visibility problem when function select from a table being modified are subjects of bug 21326). See also bug 22427.
-
- 08 Oct, 2006 3 commits
-
-
svoj@april.(none) authored
into mysql.com:/home/svoj/devel/mysql/engines/mysql-5.1-engines
-
svoj@mysql.com/april.(none) authored
-
svoj@may.pils.ru authored
into may.pils.ru:/home/svoj/devel/bk/mysql-5.1-engines
-
- 06 Oct, 2006 13 commits
-
-
svoj@april.(none) authored
into mysql.com:/home/svoj/devel/mysql/BUG22937/mysql-5.1-engines
-
svoj@mysql.com/april.(none) authored
into mysql.com:/home/svoj/devel/mysql/BUG22937/mysql-5.0-engines
-
svoj@mysql.com/april.(none) authored
into mysql.com:/home/svoj/devel/mysql/BUG22937/mysql-4.1-engines
-
svoj@mysql.com/april.(none) authored
This is addition to fix for bug21617. Valgrind reports an error when opening merge table that has underlying tables with less indexes than in a merge table itself. Copy at most min(file->keys, table->key_parts) elements from rec_per_key array. This fixes problems when merge table and subtables have different number of keys.
-
svoj@april.(none) authored
into mysql.com:/home/svoj/devel/mysql/BUG21381/mysql-5.1-engines
-
svoj@mysql.com/april.(none) authored
into mysql.com:/home/svoj/devel/mysql/BUG21381/mysql-5.0-engines
-
svoj@mysql.com/april.(none) authored
-
kroki/tomash@moonlight.intranet authored
Note: bug#21726 does not directly apply to 4.1, as it doesn't have stored procedures. However, 4.1 had some bugs that were fixed in 5.0 by the patch for bug#21726, and this patch is a backport of those fixes. Namely, in 4.1 it fixes: - LAST_INSERT_ID(expr) didn't return value of expr (4.1 specific). - LAST_INSERT_ID() could return the value generated by current statement if the call happens after the generation, like in CREATE TABLE t1 (i INT AUTO_INCREMENT PRIMARY KEY, j INT); INSERT INTO t1 VALUES (NULL, 0), (NULL, LAST_INSERT_ID()); - Redundant binary log LAST_INSERT_ID_EVENTs could be generated.
-
svoj@mysql.com/april.(none) authored
-
svoj@april.(none) authored
into mysql.com:/home/svoj/devel/mysql/BUG10974/mysql-5.1-engines
-
svoj@mysql.com/april.(none) authored
-
svoj@mysql.com/april.(none) authored
into mysql.com:/home/svoj/devel/mysql/BUG10974/mysql-5.0-engines
-
svoj@mysql.com/april.(none) authored
-
- 05 Oct, 2006 3 commits
-
-
svoj@mysql.com/april.(none) authored
-
svoj@april.(none) authored
into mysql.com:/home/svoj/devel/mysql/BUG21381/mysql-5.1-engines
-
svoj@mysql.com/april.(none) authored
into mysql.com:/home/svoj/devel/mysql/BUG21381/mysql-5.0-engines
-