This is a read-only copy of the MariaDB Knowledgebase generated on 2024-11-21. For the latest, interactive version please visit https://mariadb.com/kb/.

MariaDB 5.3.3 Changelog

Download | Release Notes | Changelog | Overview of 5.3

Release date: 21 Dec 2011

For the highlights of this release, see the release notes.

The revision number links will take you to the revision's page on Launchpad. On Launchpad you can view more details of the revision and view diffs of the code modified in that revision.

  • Revision #3367 Tue 2011-12-20 12:13:47 +0400
    • Fix version number: it's 5.3.3
  • Revision #3366 Tue 2011-12-20 09:57:42 +0400
    • Update mysql-test/suite/pbxt/r/subselect.result for the previous push
  • Revision #3365 Mon 2011-12-19 23:05:44 +0200
    • Backport of MySQL Worklog #5953 from MySQL 5.6
    • The patch differs from the original MySQL patch as follows:
      • All test case differences have been reviewed one by one, and care has been taken to restore the original plan so that each test case executes the code path it was designed for.
      • A bug was found and fixed in MariaDB 5.3 in Item_allany_subselect::cleanup().
      • ORDER BY is not removed because we are unsure of all effects, and it would prevent enabling ORDER BY ... LIMIT subqueries.
      • ref_pointer_array.m_size is not adjusted because we don't do array bounds checking, and because it looks risky.
    • Original comment by Jorgen Loland:
      • MySQL Worklog #5953 - Optimize away useless subquery clauses
      • For IN/ALL/ANY/SOME/EXISTS subqueries, the following clauses are meaningless:
        • ORDER BY (since we don't support LIMIT in these subqueries)
        • DISTINCT
        • GROUP BY if there is no HAVING clause and no aggregate functions
      • This WL detects and optimizes away these useless parts of the query during JOIN::prepare()
  • Revision #3364 Mon 2011-12-19 22:24:10 +0400
    • Bug #906385: EXPLAIN EXTENDED crashes in TABLE_LIST::print with limited max_join_size
      • Take into account that subquery's optimization can fail because of @@max_join_size error.
  • Revision #3363 Mon 2011-12-19 20:58:55 +0400
    • Bug #904432: Wrong result with LEFT JOIN, constant table, semijoin=ON,materialization=ON
      • Correct handling for SJ-Materialization + outer joins (details in the comments in the code)
  • Revision #3362 Mon 2011-12-19 18:07:19 +0400
    • Remove garbage comments
  • Revision #3361 Mon 2011-12-19 10:11:21 +0200
    • Supression condition made wider to cover some other system cases.
  • Revision #3360 Sun 2011-12-18 23:38:37 -0800
    • Fixed Bug #904832.
    • Do not perform index condition pushdown for conditions containing subqueries and stored functions.
  • Revision #3359 Sun 2011-12-18 19:25:00 +0400
    • Bump version number: now it's 5.3.3 (5.3.2 has been released some time ago)
  • Revision #3358 Fri 2011-12-16 08:05:14 -0800
    • Adjusted test cases of the suite funcs_1.
  • Revision #3357 Fri 2011-12-16 14:19:58 +0400
    • Update test results for previous push
  • Revision #3356 Fri 2011-12-16 10:21:46 +0400
    • GIS issues fixed.
    • Failures on SUN Solaris. Buggy compiler there required some extra initialization for variables. Then the 02 optimization leads to bugs when values set through the pointer are not always taken into account. Finally, the (long long) / (long) crashes there, the explicit typeconverstion added. Failing innodb_plunin.innodb_gis.test fixed.
    • per-file comments:
      • mysql-test/suite/innodb_plugin/t/innodb_gis.test
        • GIS issues fixed.
      • sql/gcalc_slicescan.cc
        • GIS issues fixed.
      • sql/gcalc_tools.cc
        • GIS issues fixed.
  • Revision #3355 [merge] Thu 2011-12-15 15:55:00 -0800
    • Merge
    • Revision #3353.1.1 [merge] Thu 2011-12-15 14:28:34 -0800
      • Merge.
      • Revision #3349.2.2 Thu 2011-12-15 14:26:59 -0800
        • Made join_cache_level == 2 by default.
      • Revision #3349.2.1 Thu 2011-12-15 00:21:15 -0800
        • Made the optimizer switch flags 'outer_join_with_cache', 'semijoin_with_cache' set to 'on' by default.
  • Revision #3354 [merge] Fri 2011-12-16 03:46:04 +0400
    • Merge
    • Revision #3349.1.2 Fri 2011-12-16 03:44:25 +0400
      • Bug #901399: Wrong result (extra row) with semijoin=ON, materialization=OFF, optimizer_prune_level=0
      • Correctly handle plan refinement stage for LooseScan plans: run create_ref_for_key() if LooseScan plan includes a ref access, and if we don't have any fixed key components, switch to a full index scan.
  • Revision #3353 Thu 2011-12-15 17:26:32 +0400
    • Fix unused variable 'thd' error.
  • Revision #3352 [merge] Thu 2011-12-15 16:47:39 +0400
    • Merge
    • Revision #3349.1.1 Thu 2011-12-15 02:49:19 +0400
      • Make MyISAM's version of create_internal_tmp_table set QPLAN_TMP_DISK, like Aria version does (otherwise slow query log would show Tmp_table_on_disk=No when it should have said Yes)
  • Revision #3351 Thu 2011-12-15 16:43:28 +0400
    • Fix trivial merge error
  • Revision #3350 [merge] Wed 2011-12-14 20:38:38 +0200
    • Merge
    • Revision #3345.1.2 [merge] Wed 2011-12-14 20:36:51 +0200
      • Merge with 5.2
      • Revision #2732.46.39 [merge] Tue 2011-12-13 20:08:41 +0200
        • Merge with 5.1
        • Updated version number in configure
        • Revision #2643.143.66 Mon 2011-12-12 16:28:16 +0100
          • new "./configure --disable-distribution" option
          • Revision #2643.143.65 Mon 2011-12-12 13:37:18 +0100
            • Fix GCC build failure in PBXT in some cases/platforms.
            • Revision #2643.143.64 Sun 2011-12-11 22:58:01 +0200
              • Fixed valgrind problem: reference on deleted memory of temporary table name. Removed previous patch of this problem.
      • Revision #2732.46.38 Tue 2011-12-13 19:57:19 +0200
        • Fixed Bug #887051 ; Error in recovery with LOAD DATA + DELETE
    • Revision #3345.1.1 Tue 2011-12-13 20:07:23 +0200
      • Fixed failure with query_cache.test for embedded server
  • Revision #3349 [merge] Wed 2011-12-14 04:56:54 +0400
    • Merge
    • Revision #3338.1.1 Wed 2011-12-14 04:39:29 +0400
      • Bug #901506: Crash in TABLE_LIST::print on EXPLAIN EXTENDED
        • Let JTBM optimization code handle the case where the subquery is degenerate and doesn't have a join query plan. Regular materialization would fall back to IN->EXISTS for such cases. Semi-Join materialization does not have such option, instead we introduce and use "constant JTBM join tabs".
  • Revision #3348 [merge] Tue 2011-12-13 14:28:53 -0800
    • Merge
    • Revision #3346.1.1 Tue 2011-12-13 14:20:47 -0800
      • Fixed Bug #902356.
      • A memory overwrite in the function test_if_skip_sort_order() could cause a crash for some queries with subqueries.
  • Revision #3347 Wed 2011-12-14 02:15:15 +0400
    • Bug #902632: Crash or invalid read at st_join_table::cleanup, st_table::disable_keyread
      • Do a "more thorough" cleanup of SJ-Materialization join tab in JOIN_TAB::cleanup. The bug was due to the fact that JOIN_TAB::cleanup() may be called multiple times for the same tab if the join has grouping.
  • Revision #3346 Tue 2011-12-13 20:52:06 +0200
    • The variable query_cache_strip_comments allowed in embedded server.
  • Revision #3345 [merge] Tue 2011-12-13 14:11:08 +0200
    • Automatic merge
    • Revision #3343.1.1 Tue 2011-12-13 14:00:20 +0200
      • Fixed valgrind error when storing db_name_length in query_cache.
        • Changed storage to be 2 bytes instead of sizeof(size_t) (simple optimization)
        • Fixed bug when using query_cache_strip_comments and query that started with '('
        • Fixed DBUG_PRINT() that used wrong (not initialized) variables.
  • Revision #3344 [merge] Mon 2011-12-12 13:00:33 +0100
    • 5.2->5.3 merge
    • Revision #2732.46.37 Mon 2011-12-12 12:36:46 +0200
    • Fixed Bug #900375
    • The range optimizer incorrectly chose a loose scan for group by when there is a correlated WHERE condition. This range access method cannot be executed for correlated conditions also with the "range checked for each record" because generally the range access method can change for each outer record. Loose scan destructively changes the query plan and removes the GROUP operation, which will result in wrong query plans if another range access is chosen dynamically.
    • Revision #2732.46.36 Thu 2011-12-08 12:05:52 +0200
    • Fixed Bug #888456
    • Analysis:
      • The class member QUICK_GROUP_MIN_MAX_SELECT::seen_first_key was not reset between subquery re-executions. Thus each subsequent execution continued from the group that was reached by the previous subquery execution. As a result loose scan reached end of file much earlier, and returned empty result where it shouldn't.
    • Solution:
      • Reset seen_first_key before each re-execution of the loose scan.
    • Revision #2732.46.35 Sat 2011-12-03 22:44:33 +0100
      • updated the version in configure
    • Revision #2732.46.34 Fri 2011-12-02 16:27:13 +0100
      • PAM plugin with test
    • Revision #2732.46.33 Fri 2011-12-02 16:26:43 +0100
      1. add --plugin-dir and --default-auth to mysqltest.
      2. dialog plugin now always returns mysql->password if non-empty and the first question is of password type
      3. split get_tty_password into get_tty_password_buff and strdup.
      4. dialog plugin now uses get_tty_password by default
      5. dialog.test
      6. moved small tests of individual plugins into a dedicated suite
    • Revision #2732.46.32 Sat 2011-12-03 10:53:00 +0100
      • update tests
  • Revision #3343 Sun 2011-12-11 19:41:53 -0800
    • Fixed Bug #901709
    • The cause of the reported assertion failure was a division of a double value by 0.
  • Revision #3342 [merge] Sun 2011-12-11 14:38:14 -0800
    • Merge
    • Revision #3339.1.1 Sun 2011-12-11 12:56:06 -0800
      • Fixed Bug #901478
      • If the duplicate elimination strategy is used for a semi-join and potentially one of the block-based join algorithms can be employed to join the inner tables of the semi-join then sorting of the head (first non-constant) table for a query with ORDER BY / GROUP BY cannot be used.
  • Revision #3341 Sun 2011-12-11 12:42:43 -0800
    • Adjusted the results of pbxt.subselect after the latest merge 5.1->5.2->5.3.
  • Revision #3340 [merge] Sun 2011-12-11 19:28:05 +0200
    • Merge with 5.1 & fixes to IGNORE handling
    • Revision #3327.1.3 Sun 2011-12-11 18:39:33 +0200
      • Rewrite IGNORE handling:
        • Instead of supressing all errors, only suppress safe ones like:
          • ER_DUP_KEY, ER_BAD_NULL_ERROR, ER_SUBQUERY_NO_1_ROW, ER_ROW_IS_REFERENCED_2
    • Revision #3327.1.2 [merge] Sun 2011-12-11 11:34:44 +0200
      • Merge with 5.2.
      • no_error handling for select (used by INSERT ... SELECT) still needs to be fixed, but I will do that in a separate commit
      • Revision #2732.46.31 [merge] Sat 2011-12-03 20:47:25 +0200
      • Revision #2732.46.30 Sat 2011-12-03 20:44:54 +0200
        • Fixed buildbot warnings
      • Revision #2732.46.29 Fri 2011-12-02 18:10:54 +0200
        • Fixed some Aria limits to be more sane
      • Revision #2732.46.28 [merge] Fri 2011-12-02 17:32:56 +0200
        • Merge
        • Revision #2732.49.1 Fri 2011-12-02 17:22:17 +0200
          • Fixed bug where automaticly zerofilled table was not part of recovery if crash happended before next checkpoint.
      • Revision #2732.46.27 Thu 2011-12-01 22:37:45 +0100
        • Fix intermittently failing variables-notembedded test case.
        • After sending packet that is too large, clienrt can get either an error packet with ER_NET_PACKET_TOO_LARGE, or a socket error. Both cases are valid, since the server does not ensure reply was fully read by client, before shutting down and closing the socket.
      • Revision #2732.46.26 Thu 2011-12-01 20:21:11 +0200
        • Fixed compiler warning
      • Revision #2732.46.25 [merge] Thu 2011-12-01 20:14:53 +0200
        • Merge with 5.1
        • Revision #2643.143.61 Thu 2011-12-01 20:11:41 +0200
          • Fixed that --with-libedit --without-readline works
          • Fixed buildbot failures (compiler warnings, failing tests)
      • Revision #2732.46.24 [merge] Wed 2011-11-30 22:57:18 +0200
        • Merge with 5.1
        • Revision #2643.143.60 Wed 2011-11-30 20:57:09 +0200
          • Fixed compiler warning and errors
        • Revision #2643.143.59 Wed 2011-11-30 18:44:51 +0200
          • Fixed compiler warnings and other bugs found by buildbot.
        • Revision #2643.143.58 Wed 2011-11-30 11:37:28 +0100
          • test both federated and federatedX in the federated suite.
        • Revision #2643.143.57 Wed 2011-11-30 13:53:25 +0100
          • Cherrypick into XtraDB: Bug#13002783 PARTIALLY UNINITIALIZED CASCADE UPDATE VECTOR<</style>>
          • We merged the test case for this into MariaDB 5.1, but the fix was not yet part of XtraDB.
        • Revision #2643.143.56 Wed 2011-11-30 00:34:05 +0200
          • Fixed compiler warnings
      • Revision #2732.46.23 [merge] Tue 2011-11-29 22:48:24 +0200
        • Merge with 5.1 + fixes for build failures in 5.2
        • Revision #2643.143.55 Tue 2011-11-29 15:32:25 +0200
          • Fixed that maria-recover works as expected.
            • "" is now used if no option is set
        • Revision #2643.143.54 Tue 2011-11-29 01:10:17 +0100
          • Fix Windows build, and a conversion truncation warning.
        • Revision #2643.143.53 Thu 2011-11-24 19:23:20 +0200
          • Fixed that one can use --maria-recover=backup,force
          • (Before we only allowed one option)
      • Revision #2732.46.22 Tue 2011-11-29 08:50:54 +0100
        • Fix testcases:
          1. main.merge fails with errno 13 in copy_file().
            • The reason for the error is that copy_file tries to create a file with the same name as recently deleted one, and there is still an open handle for the deleted file.
            • To fix, use my_delete_allow_opened() for MTR's delete_file. On Windows, this renames file to unique name prior to deletion, and prevents EACCES errors for files opened with FILE_SHARE_DELETE.
          2. innodb_bug59641
            • generates warnings, after server was killed and restarted in the test case.
            • The warnings are about test_suppression table (needs to be repaired, as it that was written just prior to the crash)
            • Fixed by using FLUSH TABLES after populating warning suppression table.
      • Revision #2732.46.21 Tue 2011-11-29 02:00:24 +0100
        • merge, fix Windows warnings
      • Revision #2732.46.20 Mon 2011-11-28 15:08:12 +0100
        • after merge fixes
      • Revision #2732.46.19 [merge] Thu 2011-11-24 22:48:35 +0200
        • Automatic merge
        • Revision #2732.48.2 Thu 2011-11-24 19:07:36 +0200
          • Added test case for Bug #875797 Using 'innodb_sys_indexes' causes core dump
        • Revision #2732.48.1 [merge] Thu 2011-11-24 18:48:58 +0200
          • Merge with MariaDB 5.1
          • Revision #2643.143.52 Thu 2011-11-24 16:04:19 +0200
            • Fixes for build failuers found by buildbot
          • Revision #2643.143.51 [merge] Wed 2011-11-23 19:32:14 +0200
            • Merge with MySQL 5.1.60
          • Revision #2643.143.50 Wed 2011-11-23 10:25:27 +0200
            • Fixes of testcases after merge with MySQL 5.1.59
          • Revision #2643.143.49 [merge] Mon 2011-11-21 19:19:37 +0200
            • Merge of XtraDB for 5.1.59
            • Revision #2643.149.1 [merge] Mon 2011-11-21 14:21:13 +0100
              • Merge XtraDB from Percona-Server-5.1.59-13 into MariaDB 5.1.
              • Revision #0.6.47 Mon 2011-11-21 13:20:15 +0100
                • Updated with changes from Percona Server 5.1.56-13, from lp:percona-server/5.1, tag Percona-Server-5.1.59-13.0.
                • Merged: revid:ignacio.nin@percona.com-20111016133841-fzpr5s89n13ft1s1
          • Revision #2643.143.48 [merge] Mon 2011-11-21 19:17:56 +0200
            • Automatic merge
            • Revision #2643.148.1 [merge] Mon 2011-11-21 19:13:14 +0200
              • Initial merge with MySQL 5.1 (XtraDB still needs to be merged)
              • Fixed up copyright messages.
      • Revision #2732.46.18 Tue 2011-11-22 21:55:11 +0100
        • fix dialog plugin to work on windows
      • Revision #2732.46.17 Tue 2011-11-15 13:14:54 +0200
        • Fix for Bug #780425 sql_buffer_result=1 gives wrong result for GROUP BY with a +# constant expression"
    • Revision #3327.1.1 Sat 2011-12-03 23:06:16 +0200
      • Added handler and temporary table usage to mytop
      • Fixed prompt on reconnect in mysql client
  • Revision #3339 Fri 2011-12-09 14:30:50 -0800
    • Fixed Bug #901312
    • The function setup_sj_materialization_part1() forgot to set the value of TABLE::map for any materialized IN subquery.
    • This could lead to wrong results for queries with subqueries that were converted to queries with semijoins.
  • Revision #3338 Thu 2011-12-08 16:29:45 +0400
    • Bug #901655 ST_BUFFER asserts with a coplicated shape.
    • Coinciding nodes can appear as a result of DOUBLE inaccuracy.
    • We should test that before we start the loop.
    • Also the spatial relations can be calculated faster if we check MBR relations first. And we do have the shape's MBR-s now.
    • per-file comments:
      • sql/gcalc_slicescan.cc
        • set_extent() method added.
        • Bug #901655 ST_BUFFER asserts with a coplicated shape.
      • sql/gcalc_slicescan.h
        • set_extent() method declared.
        • Bug #901655 ST_BUFFER asserts with a coplicated shape.
      • sql/gcalc_tools.cc
        • Bug #901655 ST_BUFFER asserts with a coplicated shape.
        • checks for equal nodes added.
      • sql/item_geofunc.cc
        • Bug #901655 ST_BUFFER asserts with a coplicated shape.
        • MBR for the shapes calculated, and MBR checks added before we start the heavy calculations.
      • sql/spatial.h
        • Bug #901655 ST_BUFFER asserts with a coplicated shape.
        • MBR::buffer() method implemented.
  • Revision #3337 Thu 2011-12-08 04:22:38 +0400
    • Small semi-join optimization improvement:
      • if we're considering FirstMatch access with one inner table, and @@optimizer_switch has semijoin_with_cache flag, calculate costs as if we used join cache (because we will be able to do so)
  • Revision #3336 [merge] Thu 2011-12-08 02:47:54 +0400
    • Merge fix for Bug #868908
    • Revision #3322.1.3 Wed 2011-12-07 23:15:57 +0400
      • Remove garbage assignments causing failures on Windows
    • Revision #3322.1.2 Wed 2011-12-07 19:21:51 +0400
      • Bug #868908: Crash in check_simple_equality() with semijoin + materialization + prepared statement
        • Part2: safety and code cleanup
    • Revision #3322.1.1 Wed 2011-12-07 01:03:00 +0400
      • Bug #868908: Crash in check_simple_equality() with semijoin + materialization + prepared statement
        • Part 1 of the fix: for semi-join merged subqueries, calling child_join->optimize() until we're done with all PS-lifetime optimizations in the parent.
  • Revision #3335 Thu 2011-12-08 02:12:48 +0400
    • Bug #901032: Wrong result for MIN/MAX on an indexed column with materialization and semijoin
      • opt_sum_query() should not assume that join tables from sj-materialization have known numbers of rows.
  • Revision #3334 Tue 2011-12-06 13:42:18 -0800
    • Fixed Bug #900469.
    • The execution plan cannot use sorting on the first table from the sequence of the joined tables if it plans to employ the block-based hash join algorithm.
  • Revision #3333 Tue 2011-12-06 02:46:42 -0800
    • Fixed Bug #899509.
    • The optimizer must ignore any possible hash join key when looking for the query execution plan with join_cache_level set to 0.
  • Revision #3332 [merge] Mon 2011-12-05 18:52:50 -0800
    • Merge
    • Revision #3330.1.1 [merge] Mon 2011-12-05 18:51:56 -0800
      • Merge
      • Revision #3328.1.1 Mon 2011-12-05 09:50:24 -0800
        • Fixed Bug #899777.
        • KEYUSE elements for a possible hash join key are not sorted by field numbers of the second table T of the hash join operation. Besides some of these KEYUSE elements cannot be used to build any key as their key expressions depend on the tables that are planned to be accessed after the table T.
        • The code before the patch did not take this into account and, as a result, execition of a query the employing block-based hash join algorithm could cause a crash or return a wrong result set.
  • Revision #3331 Tue 2011-12-06 01:04:27 +0400
    • Bug #899962: materialized subquery with join_cache_level=3
    • Make create_tmp_table() set KEY_PART_INFO attributes for the keys it creates.
    • This wasn't needed before but is needed now, when temp. tables that are results of SJ-Materialization are being used for joins.
    • This particular bug depended on HA_VAR_LENGTH_PART being set, but also added code to set HA_BLOB_PART and HA_NULL_PART when appropriate.
  • Revision #3330 Mon 2011-12-05 10:24:14 +0400
    • Update test result missed in the previous cset
  • Revision #3329 Mon 2011-12-05 01:31:42 +0400
    • Make subquery Materialization, as well as semi-join Materialization be shown in EXPLAIN as select_type==MATERIALIZED.
    • Before, we had select_type==SUBQUERY and it was difficult to tell materialized subqueries from uncorrelated scalar-context subqueries.
  • Revision #3328 Sun 2011-12-04 07:43:33 -0800
    • Fixed Bug #899696.
    • If has been decided that the first match strategy is to be used to join table T from a semi-join nest while no buffer can be employed to join this table then no join buffer can be used to join any table in the join sequence between the first one belonging to the semi-join nest and table T.
  • Revision #3327 Fri 2011-12-02 00:36:55 +0200
    • Added new file (for netware)
    • Added some file to ignore
  • Revision #3326 Fri 2011-12-02 00:34:59 +0200
    • Fixes for netware by Guenter Knauf
  • Revision #3325 Fri 2011-12-02 00:24:58 +0200
    • Patch to get MariaDB to compile on CYGWIN; By Guenter Knauf
    • Increased number of locks in thr_lock (used only when testing)
  • Revision #3324 Wed 2011-11-30 10:22:53 -0800
    • Fixed Bug #898073.
    • The tables from the same semi-join or outer join nest cannot use join buffers if in the join sequence of the query execution plan they are separated by a table that is planned to be joined without usage of a join buffer.
  • Revision #3323 [merge] Wed 2011-11-30 08:28:40 +0200
    • Merge the fix of Bug #825051
    • Revision #3321.1.1 Tue 2011-11-29 23:06:39 +0200
      • Fixed Bug #825051
      • The cause of the wrong result was that Item_ref_null_helper::get_date() didn't use a method of the *_result() family, and fetched the data for the field from the current row instead of result_field. Changed to use the correct *_result() method, like to all other similar methods of Item_ref_null_helper.
  • Revision #3322 Tue 2011-11-29 23:09:06 +0200
  • Revision #3321 Tue 2011-11-29 15:27:52 +0400
    • Bug #857066 Wrong result with ST_DISJOINT when using an index.
    • DISJOINT can't be properly optimized with the RTree keys in MyISAM also.
    • per-file comments:
      • storage/myisam/rt_index.c
        • Bug #857066 Wrong result with ST_DISJOINT when using an index.
        • don't optimize DISJOINT with the RTree keys.
  • Revision #3320 Tue 2011-11-29 02:11:13 +0400
    • Bug #857066 Wrong result with ST_DISJOINT when using an index the ST_DISJOINT can't be properly optimized with the RTree key at the moment.
    • per-file comments:
      • storage/maria/ma_rt_index.c
        • Bug #857066 Wrong result with ST_DISJOINT when using an index disabled optimization for the DISJOINT case.
  • Revision #3319 Mon 2011-11-28 15:24:07 +0200
    • Fix Bug #833777, Bug #894397
    • Analysis:
      • Bug #894397 was a consequence of a prior incorrect fix of Bug #833777 which didn't take into account that even when all tables are constant there may be correlated conditions, and the where clause is not equivalent to the constant conditions.
    • Solution:
      • When there are constant tables only, evaluate only the conditions that reference outer fields, because the constant conditions are already checked, and the where clause doesn't have other conditions than constant ones, and outer referencing ones. The fix for Bug #894397 also fixes Bug #833777
  • Revision #3318 Mon 2011-11-28 12:42:14 +0200
    • Fixed Bug #747278
    • The problem was that when we have single row subquery with no rows Item_cache(es) which represent result row was not null and being requested via element_index() returned random value.
    • The fix is setting all Item_cache(es) in NULL before executing the query (reset() method) which guaranty NULL value of whole query or its elements requested in any way if no rows was found.
    • set_null() method was added to Item_cache to guaranty correct NULL value in case of reseting the cache.
  • Revision #3317 Sat 2011-11-26 14:23:00 -0800
    • Set new default values for the optimizer switch flags 'derived_merge' and 'derived_with_keys'. Now they are set on by default.
  • Revision #3316 [merge] Sat 2011-11-26 12:27:52 +0400
    • Merge
    • Revision #3314.1.5 Fri 2011-11-25 23:54:36 +0400
      • Subquery code cleanups: - Make functions that operate on SJ_TMP_TABLE be member functions - Make Loose_scan_opt data members private
    • Revision #3314.1.4 Fri 2011-11-25 21:45:58 +0400
      • Update test results
    • Revision #3314.1.3 Fri 2011-11-25 15:48:56 +0400
      • Update test results
    • Revision #3314.1.2 Fri 2011-11-25 14:57:27 +0400
      • Remove garbage comments
    • Revision #3314.1.1 [merge] Fri 2011-11-25 14:28:43 +0400
      • Merge
      • Revision #3275.1.3 Fri 2011-11-25 05:56:58 +0400
        • Semi-join optimizations code cleanup part 2:
          • Make EXPLAIN display "Start temporary" at the start of the fanout (it used to display at the first table whose rowid gets into temp. table which is not that useful for the user)
          • Updated test results (all checked)
      • Revision #3275.1.2 Wed 2011-11-23 04:25:52 +0400
        • Semi-join optimizations code cleanup:
          • Break down POSITION/advance_sj_state() into four classes representing potential semi-join strategies.
          • Treat all strategies uniformly (before, DuplicateWeedout was special as it was the catch-all strategy. Now, we're still relying on it to be the catch-all, but are able to function,e.g. with firstmatch=on,duplicate_weedout=off.
          • Update test results (checked)
      • Revision #3275.1.1 Sat 2011-11-12 20:50:11 +0200
        • Bug #887468: Second assertion `keypart_map' failed in maria_rkey with semijoin
        • in advance_sj_state: Do not try to construct LooseScan strategy if we're already behind the last LooseScan table.
  • Revision #3315 Fri 2011-11-25 22:54:13 +0400
    • Remove garbage comment
  • Revision #3314 Thu 2011-11-24 22:56:02 -0800
    • Currently innodb_plugin does not support ICP. Part2.
  • Revision #3313 Thu 2011-11-24 23:47:50 +0200
  • Revision #3312 Thu 2011-11-24 23:15:40 +0200
    • Fix Bug #894326
    • The patch also fixes an unrelated compiler warning.
    • Analysis:
      • The temporary table created during SJ-materialization might be used for sorting for a group by operation. The sort buffers for this internal temporary table were not cleared by the execution code after each subquery re-execution. This resulted in a memory leak detected by valgrind.
    • Solution:
      • Cleanup the sort buffers for the semijon tables as well.
  • Revision #3311 Thu 2011-11-24 12:19:37 -0800 Currently innodb_plugin does not support ICP.
  • Revision #3310 Thu 2011-11-24 15:12:10 +0200
    • Fix for Bug #859375 and Bug #887458.
    • Stop attempts to apply IN/ALL/ANY optimizations to so called "fake_select" (used for ordering and filtering results of union) in union subquery execution.
  • Revision #3309 Thu 2011-11-24 16:26:13 +0400
    • fixes to make compilers happy.
    • per-file comments:
      • mysql-test/t/gis-precise.test
        • number-to-string conversion differs on Windows.
        • Have to tolerate this while GIS data is stored in doubles.
      • sql/spatial.cc
        • prev_x initialization added.
  • Revision #3308 Wed 2011-11-23 23:13:51 +0200
    • Fix Bug #893486
    • Analysis:
      • The bug is a result of an incomplete fix for Bug #869036
      • That fix didn't take into account that there may be a case when ther are no NULLs in the materialized subquery, however all columns without NULLs may not be grouped in the only non-null index. This is the case when the left subquery expression has nullable columns.
    • Solution:
      • The patch handles two missing sub-cases of the case when there are no value (non-null matches) for any outer expression, and there are both NULLs and non-NUll values in the outer reference.
        1. If the materialized subquery contains no NULLs there cannot be a partial match, because there are no NULLs in those columns where the outer reference has no NULLs.
        2. If the materialized subquery contains NULLs, but there exists a column, such that its corresponding outer expression has no NULL, and this column also has no NULL. Then there cannot be a partial match either.
  • Revision #3307 Tue 2011-11-22 17:57:33 +0400
    • Small fixes to make compilers happy.
  • Revision #3306 Tue 2011-11-22 17:32:05 +0400
    • Windows has no 'nearbyint' in libraries.
    • So removed.
  • Revision #3305 [merge] Tue 2011-11-22 12:06:46 +0200
    • Merge default materialization=on.
    • Revision #3300.2.1 [merge] Mon 2011-11-21 17:48:25 +0200
      • Merge enabling materialization=on by default.
      • Revision #3290.1.1 [merge] Mon 2011-11-21 16:56:32 +0200
        • Merge enabling of materialization=on by default with main tree.
        • Revision #3273.1.3 Wed 2011-11-09 21:29:01 +0200
          • Fixed PBXT test cases.
        • Revision #3273.1.2 Wed 2011-11-09 16:46:08 +0200
          • Removed a comment that is not true any more.
          • Consistent use of the SUBS_NOT_TRANSFORMED constant for in_strategy.
        • Revision #3273.1.1 Wed 2011-11-09 15:36:25 +0200
          • Enable subquery materialization=ON by default.
  • Revision #3304 Mon 2011-11-21 22:16:01 +0200
  • Revision #3303 Mon 2011-11-21 22:01:47 +0200
    • Fix Bug #833777
    • Fix test to pass on 32-bit machines by reducing the depth of subquery nestedness to less than 31 (sizeof(ulong)-1).
  • Revision #3302 [merge] Mon 2011-11-21 11:21:30 -0800
    • Merge.
    • Revision #3300.1.1 Mon 2011-11-21 09:06:35 -0800
      • Fixed Bug #887496
      • This bug in the function Loose_scan_opt::check_ref_access_part1 could lead to choosing an invalid execution plan employing a loose scan access to a semi-join table even in the cases when such access could not be used at all. This could result in wrong answers for some queries with IN subqueries.
  • Revision #3301 Mon 2011-11-21 18:00:55 +0200
    • Fix Bug #833777
    • Analysis:
      • The optimizer distinguishes two kinds of 'constant' conditions: expensive ones, and non-expensive ones. The non-expensive conditions are evaluated inside make_join_select(), and if false, already the optimizer detects empty query results.
      • In order to avoid arbitrarily expensive optimization, the evaluation of expensive constant conditions is delayed until execution. These conditions are attached to JOIN::exec_const_cond and evaluated in the beginning of JOIN::exec. The relevant execution logic is:
        JOIN::exec()
          {
            if (! join->exec_const_cond->val_int())
            {
              produce an empty result;
              stop execution
            }
            continue execution
            execute the original WHERE clause (that contains exec_const_cond)
           ...
          }
        
      • As a result, when an expensive constant condition is TRUE, it is evaluated twice - once through JOIN::exec_const_cond, and once through JOIN::cond. When the expensive constant condition is a subquery, predicate, the subquery is evaluated twice. If we have many levels of subqueries, this logic results in a chain of recursive subquery executions that walk a perfect binary tree. The result is that for subquries with depth N, JOIN::exec is executed O(2^N) times.
    • Solution:
      • Notice that the second execution of the constant conditions happens inside do_select(), in the branch: if (join->table_count == join->const_tables) { ... } In this case exec_const_cond is equivalent to the whole WHERE clause, therefore the WHERE clause has already been checked in the beginnig of JOIN::exec, and has been found to be true. The bug is addressed by not evaluating the WHERE clause if there was exec_const_conds, and it was TRUE.
  • Revision #3300 Mon 2011-11-21 07:00:14 -0800
    • Corrected the patch that made the optimizer switch for index condition pushdown set to 'on' by default.
  • Revision #3299 Mon 2011-11-21 05:16:16 -0800
    • Made the optimizer switch for index condition pushdown set to 'on' by default.
  • Revision #3298 Sun 2011-11-20 04:53:07 -0800
    • Fixed Bug #892725.
    • A non-first execution of a prepared statement missed a call of the TABLE_LIST::process_index_hints() method in the code of the function setup_tables().
    • At some scenarios this could lead to the choice of a quite inefficient execution plan for the base query of the prepared statement.
  • Revision #3297 Sun 2011-11-20 12:30:43 +0400
    • Fix for Bug #809849 spatial operations must be KILL-able.
      • Checks for thd->killed state added to the long loops in geometry calculations.
    • per-file comments:
      • sql/gcalc_slicescan.cc
        • Fix for Bug #809849 spatial operations must be KILL-able.
        • checks for TERMINATED_STATE added.
      • sql/gcalc_slicescan.h
        • Fix for Bug #809849 spatial operations must be KILL-able.
        • defines added to include checks for termination in the library.
      • sql/gcalc_tools.cc
        • Fix for Bug #809849 spatial operations must be KILL-able.
        • checks for TERMINATED_STATE added.
      • sql/gcalc_tools.h
        • Fix for Bug #809849 spatial operations must be KILL-able.
        • TERMINATED_STATE pointers added.
      • sql/item_geofunc.cc
        • Fix for Bug #809849 spatial operations must be KILL-able.
      • sql/item_geofunc.h
        • Fix for Bug #809849 spatial operations must be KILL-able.
  • Revision #3296 Fri 2011-11-18 13:32:21 -0800
    • Fixed Bug #891995
    • This bug in the function setup_semijoin_dups_elimination() could lead to invalid choice of the sequence of tables for which semi-join duplicate elimination was applied.
  • Revision #3295 Fri 2011-11-18 09:35:51 -0800
    • Fixed Bug #891953
    • Due to this bug the function SEL_IMERGE::or_sel_tree_with_checks() could build an inconsistent merge tree if one of the SEL_TREEs in the resulting index merge happened to contain a full key range.
    • This could trigger an assertion failure.
  • Revision #3294 Fri 2011-11-18 18:15:06 +0400
    • unused variable removed.
  • Revision #3293 Fri 2011-11-18 17:56:42 +0400
    • GCALC_CHECK_WITH_FLOAT disabled.
    • That's not a good option for an onrdinary user.
  • Revision #3292 Fri 2011-11-18 04:41:25 -0800
    • Fixed Bug #800184
    • The function key_and() erroneously called SEL_ARG::increment_use_count() when SEL_ARG::incr_refs() should had been called. This could lead to wrong values of use_count for some SEL_ARG trees.
  • Revision #3291 [merge] Thu 2011-11-17 08:00:22 -0800
  • Revision #3290 Thu 2011-11-17 18:03:47 +0400
    • small fixes to make compiler happy.
  • Revision #3289 Thu 2011-11-17 17:12:58 +0400
    • test results updated.
  • Revision #3288 [merge] Thu 2011-11-17 14:27:00 +0400
    • merging.
    • Revision #2978.3.42 [merge] Sat 2011-11-12 19:56:29 +0400
      • merging.
    • Revision #2978.3.41 Sun 2011-10-16 21:16:53 +0500
      • code cleanup.
    • Revision #2978.3.40 Sun 2011-10-16 19:55:37 +0500
      • GIS code cleanup.
    • Revision #2978.3.39 Fri 2011-10-14 18:37:40 +0500
      • #define added
    • Revision #2978.3.38 Fri 2011-10-14 17:57:07 +0500
      • repeating calcualtions eliminated.
    • Revision #2978.3.37 Fri 2011-10-14 16:10:55 +0500
      • GIS code.
      • Forward calculations introduced.
      • per-file comments:
        • sql/gcalc_slicescan.cc
        • sql/gcalc_slicescan.h
        • sql/gcalc_tools.cc
        • sql/gcalc_tools.h
        • sql/item_geofunc.cc
    • Revision #2978.3.36 Thu 2011-10-06 17:41:28 +0500
      • Copyright notices fixed.
    • Revision #2978.3.35 Wed 2011-10-05 14:45:39 +0500
      • Valgrind warning fixed.
      • Coordinate size limitation removed.
      • per-file comments:
        • mysql-test/r/gis-precise.result
          • test result updated.
        • sql/gcalc_slicescan.cc
          • Check coordinate extent to pick better precidion in the ::set_double()
        • sql/gcalc_slicescan.h
          • free_list() can lead to valgrind warnig. Fixed
        • sql/gcalc_tools.cc
          • free_list() call changed.
    • Revision #2978.3.34 Tue 2011-10-04 15:29:39 +0500
      • GIS code cleanup.
      • GCALC_xxx macros fixed for the GCALC_DBUG_OFF case.
      • per-file comments:
        • sql/gcalc_slicescan.h
          • GIS code cleanup.
    • Revision #2978.3.33 Tue 2011-10-04 15:01:21 +0500
      • GIS library code cleanup.
      • GCALC_DBUG_OFF and related infrastructure defined so we can enable/disable debugging conveniently.
      • per-file comments:
        • sql/gcalc_slicescan.cc
          • GIS library code cleanup.
        • sql/gcalc_slicescan.h
          • GIS library code cleanup.
        • sql/gcalc_tools.cc
          • GIS library code cleanup.
        • sql/gcalc_tools.h
          • GIS library code cleanup.
    • Revision #2978.3.32 Fri 2011-09-23 17:00:36 +0500
      • Bug #857087 Wrong result with ST_INTERSECTS and LINESTRINGs
      • Line autointersection point was treated as if it doesn't belong to the line.
      • It's in some way logical, but seems to confuse people. Fixed.
      • per_file_comments:
        • mysql-test/r/gis-precise.result
          • Bug #857087 Wrong result with ST_INTERSECTS and LINESTRINGs
          • test result updated.
        • mysql-test/t/gis-precise.test
          • Bug #857087 Wrong result with ST_INTERSECTS and LINESTRINGs
          • test case added.
        • sql/gcalc_tools.cc
          • Bug #857087 Wrong result with ST_INTERSECTS and LINESTRINGs
          • Point of line autointersection handled as it belongs to the line.
        • sql/gcalc_tools.h
          • Bug #857087 Wrong result with ST_INTERSECTS and LINESTRINGs
          • Gcalc_function::set_i_state() added
    • Revision #2978.3.31 Fri 2011-09-23 15:36:56 +0500
      • Bug #857050 ST_WITHIN returns wrong result with MULTIPOINT and POLYGON actually only testcase added as the bug was fixed already.
      • modified:
        • mysql-test/r/gis-precise.result
          • Bug #857050 ST_WITHIN returns wrong result with MULTIPOINT and POLYGON
          • test result updated.
        • mysql-test/t/gis-precise.test
          • Bug #857050 ST_WITHIN returns wrong result with MULTIPOINT and POLYGON
          • test case added.
        • sql/gcalc_tools.cc
          • superfluous variable removed.
    • Revision #2978.3.30 Fri 2011-09-23 15:25:48 +0500
      • fix for Bug #857051 ST_EQUALS returns TRUE on two nonidentical MULTIPOINTs
      • The 'single point' event was forgotten in the relation's calculation
      • per-file comments:
        • mysql-test/r/gis-precise.result
          • fix for Bug #857051 ST_EQUALS returns TRUE on two nonidentical MULTIPOINTs
          • test result updated.
        • mysql-test/t/gis-precise.test
          • fix for Bug #857051 ST_EQUALS returns TRUE on two nonidentical MULTIPOINTs
          • test case added.
        • sql/gcalc_tools.cc
          • fix for Bug #857051 ST_EQUALS returns TRUE on two nonidentical MULTIPOINTs
          • scev_single_point is properly handled.
    • Revision #2978.3.29 Fri 2011-09-23 15:05:36 +0500
      • fix for 857050 ST_WITHIN returns wrong result with MULTIPOINT and POLYGON return GEOMETRYCOLLECTION EMPTY, not NULL for the query
      • per-file comments:
        • mysql-test/r/gis.result
          • fix for 857050 ST_WITHIN returns wrong result with MULTIPOINT and POLYGON test result updated.
        • sql/spatial.cc
          • fix for 857050 ST_WITHIN returns wrong result with MULTIPOINT and POLYGON return of the Geometry::envelope() changed for the empty geometry.
    • Revision #2978.3.28 Thu 2011-09-22 18:53:36 +0500
      • fixed bugs
        • Bug #855485 ST_CROSSES returns different result than PostGIS for overlapping polygons
        • Bug #855487 ST_WITHIN returns wrong result for partially overlapping polygons
        • Bug #855492 ST_WITHIN returns TRUE on point on the edge of a polygon
        • Bug #855497 ST_ENVELOPE of GEOMETRYCOLLECTION EMPTY returns NULL and not GEOMETRYCOLLECTION EMPTY
        • Bug #855503 ST_EQUALS reports TRUE between a POLYGON and a MULTILINESTRING
        • Bug #855505 ST_TOUCHES reports TRUE for intersecting polygon and linestring
      • Changed the way weird functions like Crosses or Touches treated.
      • Added BORDER handling to the Gcalc_function.
      • per-file comments:
        • mysql-test/r/gis-precise.result
          • GIS bugs fixed.
          • test result updated.
        • mysql-test/t/gis-precise.test
          • GIS bugs fixed.
          • test cases added.
        • sql/gcalc_slicescan.h
          • GIS bugs fixed.
        • sql/gcalc_tools.cc
          • GIS bugs fixed.
        • sql/gcalc_tools.h
          • GIS bugs fixed.
        • sql/item_create.cc
          • GIS bugs fixed.
        • sql/item_geofunc.cc
          • GIS bugs fixed.
        • sql/item_geofunc.h
          • GIS bugs fixed.
        • sql/spatial.cc
          • GIS bugs fixed.
    • Revision #2978.3.27 Wed 2011-09-21 13:26:21 +0500
      • Bug #855336 ST_LENGTH does not work on GEOMETRYCOLLECTIONs fixed.
      • per-file comments:
        • mysql-test/r/gis.result
          • Bug #855336 ST_LENGTH does not work on GEOMETRYCOLLECTIONs fixed.
          • test result updated.
        • mysql-test/t/gis.test
          • Bug #855336 ST_LENGTH does not work on GEOMETRYCOLLECTIONs fixed.
          • test case added.
        • sql/item_geofunc.cc
          • Bug #855336 ST_LENGTH does not work on GEOMETRYCOLLECTIONs fixed.
          • geom_length() call fixed.
        • sql/spatial.cc
          • Bug #855336 ST_LENGTH does not work on GEOMETRYCOLLECTIONs fixed.
          • Geometry_collection::geom_length implemented.
        • sql/spatial.h
          • Bug #855336 ST_LENGTH does not work on GEOMETRYCOLLECTIONs fixed.
          • Geometry_collection::geom_length declaration added.
    • Revision #2978.3.26 Wed 2011-09-21 12:50:03 +0500
      • fix for Bug #848926 GIS functions return "GEOMETRYCOLLECTION()" instead of "GEOMETRYCOLLECTION EMPTY"
      • per-file comments:
        • mysql-test/r/gis.result
          • fix for Bug #848926 GIS functions return "GEOMETRYCOLLECTION()" instead of "GEOMETRYCOLLECTION EMPTY"
          • test result updated.
        • mysql-test/t/gis.test
          • fix for Bug #848926 GIS functions return "GEOMETRYCOLLECTION()" instead of "GEOMETRYCOLLECTION EMPTY"
          • test case added.
        • sql/gstream.cc
          • fix for Bug #848926 GIS functions return "GEOMETRYCOLLECTION()" instead of "GEOMETRYCOLLECTION EMPTY"
          • lookup_next_word() implemented.
        • sql/gstream.h
          • fix for Bug #848926 GIS functions return "GEOMETRYCOLLECTION()" instead of "GEOMETRYCOLLECTION EMPTY"
          • lookup_next_word() added.
        • sql/spatial.cc
          • fix for Bug #848926 GIS functions return "GEOMETRYCOLLECTION()" instead of "GEOMETRYCOLLECTION EMPTY"
          • name changed for the empty geometry.
        • sql/spatial.h
          • fix for Bug #848926 GIS functions return "GEOMETRYCOLLECTION()" instead of "GEOMETRYCOLLECTION EMPTY"
          • declarations modified.
    • Revision #2978.3.25 Wed 2011-09-21 09:29:37 +0500
      • bugs fixed
        • Bug #855253 Compiler error: gcalc_slicescan.cc:2036: error: suggest parentheses around comparison in operand of .|. in maria-5.3-gis
        • Bug #850775 ST_AREA does not work on GEOMETRYCOLLECTIONs in maria-5.3-gis
      • per-file comments:
        • mysql-test/r/gis.result
          • test result updated.
        • mysql-test/t/gis.test
          • test case added for 850775.
        • sql/gcalc_slicescan.cc
          • compiler error fixed.
        • sql/spatial.cc
          • ST_AREA implementation for GEOMETRY_COLLECTION, POINT and LINESTRING.
        • sql/spatial.h
          • area() declarations added.
    • Revision #2978.3.24 Wed 2011-09-21 00:04:41 +0500
      • several bugs fixed here.
        • Bug #849789 Second assertion `m_poly_borders->next' failed in Gcalc_operation_reducer::count_slice in maria-5.3-gis
        • Bug #849791 Fourth assertion `n > 0 && n < SINUSES_CALCULATED*2+1' in get_n_sincos
        • Bug #849789 Second assertion `m_poly_borders->next' failed in Gcalc_operation_reducer::count_slice in maria-5.3-gis
        • Bug #848901 Assertion `fabs(cur_isc->x-m_cur_intersection->x) + fabs(cur_isc->y-m_cur_intersection->y) < 0.000000000001' failed in Gcalc_scan_iterator::intersection_scan() in maria-5.3-gis
      • per-file comments:
        • mysql-test/r/gis-precise.result
          • test result updated.
        • mysql-test/r/gis.result
          • test result updated.
        • sql/gcalc_slicescan.cc
          • bugfixes.
        • sql/gcalc_slicescan.h
          • bugfixes.
        • sql/gcalc_tools.cc
          • bugfixes.
        • sql/gcalc_tools.h
          • bugfixes.
        • sql/item_geofunc.cc
          • bugfixes.
        • sql/spatial.cc
          • bugfixes.
    • Revision #2978.3.23 Tue 2011-09-13 18:26:16 +0500
      • Fix for Bug #848939 Wrong result with ST_INTERSECTION between linestrings and a polygon in 5.3-gis
        • Coordinates were mistakenly reversed for MULTIPOINT.
      • per-file comments:
        • mysql-test/r/gis-precise.result
          • Fix for Bug #848939 Wrong result with ST_INTERSECTION between linestrings and a polygon in 5.3-gis
          • test result updated.
        • mysql-test/t/gis-precise.test
          • Fix for Bug #848939 Wrong result with ST_INTERSECTION between linestrings and a polygon in 5.3-gis
          • test case added.
        • sql/gcalc_tools.cc
          • Fix for Bug #848939 Wrong result with ST_INTERSECTION between linestrings and a polygon in 5.3-gis
          • coordinates set in the proper order.
    • Revision #2978.3.22 Tue 2011-09-13 15:19:55 +0500
      • Fix for Bug #848901 Assertion `fabs(cur_isc->x-m_cur_intersection->x) + fabs(cur_isc->y-m_cur_intersection->y) < 0.000000000001' failed in Gcalc_scan_iterator::intersection_scan() in maria-5.3-gis
      • That assertion's check was too tight. Released it a bit.
      • per-file comments:
        • mysql-test/r/gis-precise.result
        • mysql-test/t/gis-precise.test
        • sql/gcalc_slicescan.cc
          • Fix for Bug #848901
          • The DBUG_ASSERT check is too tight here.
    • Revision #2978.3.21 Tue 2011-09-13 13:59:11 +0500
      • Fix for few similar bugs:
        • Bug #841622 Assertion `t->rp->type == Gcalc_function::shape_line' failed in Gcalc_operation_reducer::end_line in maria-5.3-gi
        • Bug #841625 Assertion `m_poly_borders->next' failed in Gcalc_operation_reducer::count_slice in maria-5.3-gis
        • Bug #841638 Assertion `!m_prev || m_prev->x != x || m_prev->y != y' failed in Gcalc_shape_transporter::int_add_point in maria-5.3-gis
        • Bug #841662 Third assertion `n > 0 && n < SINUSES_CALCULATED*2+1' in get_n_sincos
        • Bug #841745 Assertion `!sp0->is_bottom()' failed in Gcalc_scan_iterator::find_intersections in maria-5.3-gis
      • They mostly was caused by inprecision of double arithmetic.
        • Fixed by changes in how to handle multiple intersections to keep their order right.
        • Also ST_DISTANCE(GEOM, EMPTY_GEOM) was defined as NULL.
      • per-file comments:
        • mysql-test/r/gis-precise.result
          • GIS bugfixes.
            • test result updated.
        • mysql-test/t/gis-precise.test
          • GIS bugfixes.
            • test cases added.
        • sql/gcalc_slicescan.cc
          • GIS bugfixes.
            • If intersections are close, add order checks to cope with the double calcualtions imprecision.
        • sql/gcalc_slicescan.h
          • GIS bugfixes.
            • n_row parameter added to intersection to check their order.
        • sql/item_geofunc.cc
          • GIS bugfixes.
            • ST_DISTANCE(GEOM, EMPTY_GEOM) returns NULL.
    • Revision #2978.3.20 Mon 2011-09-05 09:49:46 +0500
      • Bug #839327 Crash in Gcalc_operation_reducer::end_couple with ST_UNION and MULTIPOLYGONs in 5.3-gis.
      • When edges of a polygon coicide, it can form an pike, that is turned into a line after an operation.
      • In this case a former polygon point can be an end of a single line, and that case wasn't properly handled.
      • per-file comments:
        • mysql-test/r/gis-precise.result
          • Bug #839327 Crash in Gcalc_operation_reducer::end_couple with ST_UNION and MULTIPOLYGONs in 5.3-gis.
            • test result updated.
        • mysql-test/t/gis-precise.test
          • Bug #839327 Crash in Gcalc_operation_reducer::end_couple with ST_UNION and MULTIPOLYGONs in 5.3-gis.
            • test case added.
        • sql/gcalc_tools.cc
          • Bug #839327 Crash in Gcalc_operation_reducer::end_couple with ST_UNION and MULTIPOLYGONs in 5.3-gis.
            • in the scev_two_ends case check if we have single line ending on a polygon node.
    • Revision #2978.3.19 Mon 2011-09-05 09:13:58 +0500
      • Bug #839318 Crash in Gcalc_scan_iterator::point::get_shape with ST_DISTANCE and MULTILINESTRING in maria-5.3-gis.
        • wrong variable was used as a result of inattentive copypaste.
      • per-file comments:
        • mysql-test/r/gis-precise.result
          • Bug #839318 Crash in Gcalc_scan_iterator::point::get_shape with ST_DISTANCE and MULTILINESTRING in maria-5.3-gis.
          • test result updated.
        • mysql-test/t/gis-precise.test
          • Bug #839318 Crash in Gcalc_scan_iterator::point::get_shape with ST_DISTANCE and MULTILINESTRING in maria-5.3-gis.
          • test case added.
        • sql/item_geofunc.cc
          • Bug #839318 Crash in Gcalc_scan_iterator::point::get_shape with ST_DISTANCE and MULTILINESTRING in maria-5.3-gis.
          • use 'ev' variable instead of the 'evpos'.
    • Revision #2978.3.18 Sun 2011-09-04 23:48:17 +0500
      • Bug #839341 100% CPU usage with ST_UNION in maria-5.3-gis.
        • Line loops weren't recognized when collect results.
        • Fixed by checking if we got the same beginning point of the line.
      • per-file comments:
        • mysql-test/r/gis-precise.result
          • Bug #839341 100% CPU usage with ST_UNION in maria-5.3-gis.
          • test result updated.
        • mysql-test/t/gis-precise.test
          • Bug #839341 100% CPU usage with ST_UNION in maria-5.3-gis.
          • test case added.
        • sql/gcalc_tools.cc
          • Bug #839341 100% CPU usage with ST_UNION in maria-5.3-gis.
          • check if we get the beginning node of the linestring, then cut the loop.
    • Revision #2978.3.17 Sun 2011-09-04 19:11:04 +0500
      • Bug #801466 ST_INTERSECTION() returns invalid value on empty intersection in maria-5.3-gis.
        • We didn't implement an empty geometry. And returning NULL instead of it is not quite correct. So here is the implementation of the empty value as GEOMETRYCOLLECTION().
      • per-file comments:
        • mysql-test/r/gis-precise.result
          • Bug #801466 ST_INTERSECTION() returns invalid value on empty intersection in maria-5.3-gis.
            • test result updated.
        • mysql-test/r/gis.result
          • Bug #801466 ST_INTERSECTION() returns invalid value on empty intersection in maria-5.3-gis.
            • test result updated.
        • mysql-test/t/gis-precise.test
          • Bug #801466 ST_INTERSECTION() returns invalid value on empty intersection in maria-5.3-gis.
            • test case added.
        • mysql-test/t/gis.test
          • Bug #801466 ST_INTERSECTION() returns invalid value on empty intersection in maria-5.3-gis.
            • test case added.
        • sql/field.cc
          • Bug #801466 ST_INTERSECTION() returns invalid value on empty intersection in maria-5.3-gis.
            • store GEOMETRYCOLLECTION() properly.
        • sql/gcalc_tools.cc
          • Bug #801466 ST_INTERSECTION() returns invalid value on empty intersection in maria-5.3-gis.
            • create the GEOMETRYCOLLECTION() for the empty result.
        • sql/gstream.h
          • Bug #801466 ST_INTERSECTION() returns invalid value on empty intersection in maria-5.3-gis.
            • next_symbol() added.
        • sql/spatial.cc
          • Bug #801466 ST_INTERSECTION() returns invalid value on empty intersection in maria-5.3-gis.
            • code modified to handle 0 geometries in the GEOMETRYCOLLECTION properly.
    • Revision #2978.3.16 Fri 2011-09-02 09:38:17 +0500
    • Revision #2978.3.15 Thu 2011-09-01 11:44:56 +0500
      • PostGIS-style 'same point' handling.
    • Revision #2978.3.14 Wed 2011-07-13 14:57:27 +0500
      • Fix for Bug #804266 Memory corruption/valgrind warning/crash in move_hole() with ST_UNION.
      • Second smaller hole in the polygon got link to the bigger one as it's the outer ring. Fixed by specifying the outer ring explicitly.
      • per-file comments:
        • mysql-test/r/gis-precise.result
          • Fix for Bug #804266 Memory corruption/valgrind warning/crash in move_hole() with ST_UNION.
            • test result updated.
        • mysql-test/t/gis-precise.test
          • Fix for Bug #804266 Memory corruption/valgrind warning/crash in move_hole() with ST_UNION.
            • test case added.
        • sql/gcalc_tools.cc
          • Fix for Bug #804266 Memory corruption/valgrind warning/crash in move_hole() with ST_UNION.
            • specify the outer ring explicitly in the get_polygon_result parameter.
        • sql/gcalc_tools.h
          • Fix for Bug #804266 Memory corruption/valgrind warning/crash in move_hole() with ST_UNION.
            • add the outer ring as a parameter to the get_polygon_result.
    • Revision #2978.3.13 Tue 2011-07-12 11:21:20 +0500
      • Fix for Bug #801217 Assertion `t1->result_range' in Gcalc_operation_reducer::end_couple.
        • We cannot cut a line from a polygon. So if the polygon fits the condition, and the intersection of a line and the polygon doesn't, we just skip the line.
        • That rule wasn't applied if the line start was inside the polygon, which leaded to the assertion.
      • per-file comments:
        • mysql-test/r/gis-precise.result
          • Fix for Bug #801217 Assertion `t1->result_range' in Gcalc_operation_reducer::end_couple.
            • test result updated.
        • mysql-test/t/gis-precise.test
          • Fix for Bug #801217 Assertion `t1->result_range' in Gcalc_operation_reducer::end_couple.
            • test case added.
        • sql/gcalc_tools.cc
          • Fix for Bug #801217 Assertion `t1->result_range' in Gcalc_operation_reducer::end_couple.
            • Don't mark the line as a border if it's inside a polygon that fits the result condition.
    • Revision #2978.3.12 Fri 2011-07-08 15:38:15 +0500
      • Fix for Bug #804259 Second assertion in Gis_geometry_collection::init_from_opresult.
        • A polygon has no right to have holes that are actually points.
        • So just skip them when we collect the result of an operation.
      • per-file comments:
        • mysql-test/r/gis-precise.result
          • Fix for Bug #804259 Second assertion in Gis_geometry_collection::init_from_opresult.
            • test result updated.
        • mysql-test/t/gis-precise.test
          • Fix for Bug #804259 Second assertion in Gis_geometry_collection::init_from_opresult.
            • test case added.
        • sql/gcalc_tools.cc
          • Fix for Bug #804259 Second assertion in Gis_geometry_collection::init_from_opresult.
            • Skip the point in the result if it's the hole inside a polygon.
    • Revision #2978.3.11 Thu 2011-07-07 21:30:51 +0500
      • Fix for Bug #805860 Second assertion Assertion `n > 0 && n < SINUSES_CALCULATED*2+1' in get_n_sincos.
        • Just typo-style mistake. Should be '||' instead of '&&'.
      • per-file comments:
        • mysql-test/r/gis-precise.result
          • Fix for Bug #805860 Second assertion Assertion `n > 0 && n < SINUSES_CALCULATED*2+1' in get_n_sincos.
            • test result updated.
        • mysql-test/t/gis-precise.test
          • Fix for Bug #805860 Second assertion Assertion `n > 0 && n < SINUSES_CALCULATED*2+1' in get_n_sincos.
            • test case added.
        • sql/item_geofunc.cc
          • Fix for Bug #805860 Second assertion Assertion `n > 0 && n < SINUSES_CALCULATED*2+1' in get_n_sincos.
            • condition fixed.
    • Revision #2978.3.10 Thu 2011-07-07 16:59:45 +0500
      • Fix for Bug #804324 Assertion 0 in Gcalc_scan_iterator::pop_suitable_intersection
        • There were actually two bugs. One was when the line that intersects itself the intersection point treated as it doesn't belong to the line.
        • Second when edges partly coincide, wrong result produced when we try to find their intersection.
      • per-file comments:
        • mysql-test/r/gis-precise.result
          • Fix for Bug #804324 Assertion 0 in Gcalc_scan_iterator::pop_suitable_intersection
            • test result updated.
        • mysql-test/t/gis-precise.test
          • Fix for Bug #804324 Assertion 0 in Gcalc_scan_iterator::pop_suitable_intersection
            • test case added.
        • sql/gcalc_slicescan.cc
          • Fix for Bug #804324 Assertion 0 in Gcalc_scan_iterator::pop_suitable_intersection
            • skip the intersection if it just line that intersects itself.
        • sql/gcalc_tools.cc
          • Fix for Bug #804324 Assertion 0 in Gcalc_scan_iterator::pop_suitable_intersection
            • if edges coincide, just pick the first coinciding poing as an intersection.
    • Revision #2978.3.9 Tue 2011-07-05 19:42:35 +0500
      • Bug #804305 Crash in wkb_get_double with ST_INTERSECTION.
      • That crash happened with the complicated topology of the result.
      • If we found a hole in a polygon whose outside border was already found, we need to paste the hole right after it and respectively shift polygons after it. Also we need to update poly_position fields in these polygons. That last thing wasn't properly done that led to the crash.
      • To fix that we keep the list of the found polygons and update the poly_positions that are bigger or equal to where we placed the next hole.
      • per-file comments:
        • mysql-test/r/gis-precise.result
          • Bug #804305 Crash in wkb_get_double with ST_INTERSECTION.
            • test result updated.
        • mysql-test/t/gis-precise.test
          • Bug #804305 Crash in wkb_get_double with ST_INTERSECTION.
            • test result added.
        • sql/gcalc_tools.cc
          • Bug #804305 Crash in wkb_get_double with ST_INTERSECTION.
            • keep the list of the found polygons and update their poly_position fields respectively.
        • sql/gcalc_tools.h
          • Bug #804305 Crash in wkb_get_double with ST_INTERSECTION.
            • Gcalc_result_receiver::move_hole interface changed.
    • Revision #2978.3.8 Mon 2011-07-04 16:17:34 +0500
      • fix for Bug #801212 Assertion with ST_INTERSECTION on NULL values
        • The ::val_str() method has to return NULL if it calculated the null_value, not just set the related flag.
      • per-file comments:
        • mysql-test/r/gis-precise.result
          • fix for Bug #801212 Assertion with ST_INTERSECTION on NULL values
            • test result updated.
        • mysql-test/t/gis-precise.test
          • fix for Bug #801212 Assertion with ST_INTERSECTION on NULL values
            • test case added.
        • sql/item_geofunc.cc
          • fix for Bug #801212 Assertion with ST_INTERSECTION on NULL values
            • return NULL from the val_str if we get the null_value.
    • Revision #2978.3.7 Mon 2011-07-04 16:03:36 +0500
      • Bug #801199 Infinite recursion in Gcalc_function::count_internal with ST_BUFFER over MULTIPOINT
        • Collections were treated mistakenly, so the counter for the final UNION operation received the wrong value.
        • As a fix we implement Item_func_buffer::Transporter::start_collection() method, where we set the proper operation and the operand counter. start_poly() and start_line() were also modified to function correctly for the polygon as a part of a collection.
      • per-file comments:
        • mysql-test/r/gis-precise.result
          • Bug #801199 Infinite recursion in Gcalc_function::count_internal with ST_BUFFER over MULTIPOINT
            • test result updated.
        • mysql-test/t/gis-precise.test
          • Bug #801199 Infinite recursion in Gcalc_function::count_internal with ST_BUFFER over MULTIPOINT
            • test case added.
        • sql/item_geofunc.cc
          • Bug #801199 Infinite recursion in Gcalc_function::count_internal with ST_BUFFER over MULTIPOINT
            • start_collection() implemented.
        • sql/item_geofunc.h
          • Bug #801199 Infinite recursion in Gcalc_function::count_internal with ST_BUFFER over MULTIPOINT
            • Item_func_buffer::Transporter::start_collection() defined.
    • Revision #2978.3.6 Thu 2011-06-30 19:24:52 +0500
      • fix for Bug #201189 ST_BUFFER asserts if radius = 0.
        • Internal caclucations can't handle zero distance properly.
        • As the ST_BUFFER(geom, 0) is in fact NOOP, we'll just return the
          • 'geom' as the result here.
      • per-file comments:
        • mysql-test/r/gis-precise.result
          • fix for Bug #201189 ST_BUFFER asserts if radius = 0.
            • test result updated.
        • mysql-test/t/gis-precise.test
          • fix for Bug #201189 ST_BUFFER asserts if radius = 0.
            • test case added.
        • sql/item_geofunc.cc
          • fix for Bug #201189 ST_BUFFER asserts if radius = 0.
            • return the first argument as the result of the ST_BUFFER, if the distance is 0 there.
    • Revision #2978.3.5 Thu 2011-06-30 18:18:27 +0500
      • fix for Bug #801243 Assertion `(0)' failed in Gis_geometry_collection::init_from_opresult on ST_UNION
        • If the result contains a polygon with a hole, consequitive shapes weren't calculated properly, as the hole appeared as shape in the result, but actually it's a single shape with the surrounding polygon. It's more natural to use the size of the result as a border instead of the number of resulting shapes.
      • per-file comments:
        • mysql-test/r/gis-precise.result
          • fix for Bug #801243 Assertion `(0)' failed in Gis_geometry_collection::init_from_opresult on ST_UNION
          • test result updated.
        • mysql-test/t/gis-precise.test
          • fix for Bug #801243 Assertion `(0)' failed in Gis_geometry_collection::init_from_opresult on ST_UNION
          • test case added.
        • sql/spatial.cc
          • fix for Bug #801243 Assertion `(0)' failed in Gis_geometry_collection::init_from_opresult on ST_UNION
          • check the data lenght instead of number of shapes.
        • sql/spatial.h
          • fix for Bug #801243 Assertion `(0)' failed in Gis_geometry_collection::init_from_opresult on ST_UNION
          • check the data lenght instead of number of shapes.
    • Revision #2978.3.4 [merge] Mon 2011-06-20 00:21:41 +0500
      • gis-related tests fixes.
      • merging.
      • Revision #2978.3.3 Tue 2011-06-14 11:20:48 +0500
        • Precision spatial function tests added.
      • Revision #2978.3.2 Thu 2011-05-05 14:30:59 +0500
        • forgotten h-files added to the NOINST_HEADERS
      • Revision #2978.3.1 Wed 2011-05-04 23:20:17 +0500
        • Precise GIS functions added.
  • Revision #3287 Thu 2011-11-17 01:00:46 -0800
    • Fixed Bug #891052.
    • Some optimizer switches were missing in the help lists of mysqld.
  • Revision #3286 Thu 2011-11-17 01:25:10 +0200
    • Fix Bug #869036
    • Apart from the fix, the patch also adds few more unrelated test cases for partial matching, and fixes few typos.
    • Analysis:
      • This bug uncovered that partial matching via rowid intersection didn't handle the case when:
        • the left IN argument has some NULLs,
        • there are no non-null value matches, and there is no non-null column,
        • the subquery columns that are not covered with the NULLs in the left IN argument contain at least one row, such that it has NULL values in all columns where the left IN operand has no NULLs.
      • In this case there is a partial match.
      • In addition the analysis of the related code uncovered incorrect handling of few other related cases.
    • Solution:
      • The solution for the bug is to check if there exists a row with NULLs in all columns other than the ones having NULL in the let IN operand.
      • The check is implemented via checking whether the bitmaps that store NULL information in class Ordered_key have a non-empty intersection for the relevant columns.
      • The intersection itself is implemented via the function bitmap_exists_intersection() in my_bitmap.c.
  • Revision #3285 Wed 2011-11-16 06:11:25 -0800
    • Fixed Bug #887479.
    • The function setup_semijoin_dups_elimination erroneously assumed that if join_cache_level is set to 3 or 4 then the type of the access to a table cannot be JT_REF or JT_EQ_REF. This could lead to wrong query result sets.
  • Revision #3284 [merge] Tue 2011-11-15 14:35:36 -0800
    • Merge.
    • Revision #3278.1.1 Tue 2011-11-15 13:03:00 -0800
      • Fixed Bug #889750.
      • If the optimizer switch 'semijoin_with_cache' is set to 'off' then join cache cannot be used to join inner tables of a semijoin.
      • Also fixed a bug in the function check_join_cache_usage() that led to wrong output of the EXPLAIN commands for some test cases.
  • Revision #3283 Mon 2011-11-14 19:24:36 +0200
    • Fix Bug #889744
    • MariaDB 5.5 merges changes from MySQL 5.5 where all constant expressions are wrapped into an Item_cache. As a result, constant single-row subqueries were also wrapped in an Item_cache. When analyzing the where clause for constant expressions that can be evaluated during optimization, subqueries wrapped into an Item_cache did not appear as expensive, and were therefore evaluated during optimization. Such evaluation is against the current architecture of MariaDB 5.3 where subquries are executed during the execute phase.
    • The patch adds the is_expensive() predicate to Item_cache.
    • This makes Item_cache consistent with other wrapping Item classes that need to look at the properties of the wrapped object.
  • Revision #3282 [merge] Mon 2011-11-14 00:32:21 +0100
    • 5.2->5.3 merge
    • Revision #2732.46.16 [merge] Sun 2011-11-13 18:41:45 +0100
      • 5.1->5.2 merge
      • Revision #2643.143.47 Sun 2011-11-13 13:28:35 +0100
        • don't make feedback_plugin_send.test as 'big'
        • don't assume that the http reply packet will arrive in all in one piece
  • Revision #3281 Sun 2011-11-13 12:02:13 +0200
    • Fix for Bug #824425: Prohibiting subqueries in rows for left part of IN/ALL/ANY
    • Fix for walk() method of subqueries: always call the method on the subquery.
  • Revision #3280 [merge] Sun 2011-11-13 09:10:45 +0100
  • Revision #3279 [merge] Sat 2011-11-12 18:08:12 +0100
    • 5.2->5.3 merge
    • Revision #2732.46.14 [merge] Sat 2011-11-12 16:47:14 +0100
      • 5.1 merge
      • Revision #2643.143.45 Sat 2011-11-12 16:41:00 +0100
        • feedback plugin:
          • fix for mem_total on windows
          • report the time of the data snapshot
      • Revision #2643.143.44 Tue 2011-11-08 23:07:19 +0100
        • typos fixed
          • (thanks viva64.com)
    • Revision #2732.46.13 [merge] Fri 2011-11-04 12:41:27 +0200
      • Merge of gcc 4.6 fixes
      • Revision #2732.47.2 Thu 2011-10-27 19:18:25 +0300
        • Fix gcc 4.6 warning after merge with 5.1
      • Revision #2732.47.1 [merge] Thu 2011-10-27 17:51:30 +0300
        • 5.1->5.2 merge (gcc 4.6 warnings and apple hwaddress fixes).
        • Revision #2643.143.43 Thu 2011-10-27 15:22:52 +0300
          • Fix gcc 4.6 warnings about assigned but not used variables.
          • Fixed my_gethwaddr.c to allow compilation on Mac OS X.
    • Revision #2732.46.12 Tue 2011-11-01 12:36:43 +0400
      • Bug #884184: Wrong result with RIGHT JOIN + derived_merge
        • Make eliminate_tables_for_list() take into account that it is not possible to eliminate a table if it is used in the upper-side ON expressions. Example:
          xxx JOIN (t1 LEFT JOIN t2 ON cond ) ON func(t2.columns)
        • Here it would eliminate t2 which is not possible because of use of t2.columns.
  • Revision #3278 [merge] Sat 2011-11-12 03:57:46 -0800
    • Merge.
    • Revision #3148.1.1 Sat 2011-11-12 02:20:44 -0800
      • Fixed Bug #823301
      • A bug in the code of the function key_or could lead to a situation when performing of an OR operation for one index changes the result the operation for another index. This bug is fixed with this patch.
      • Also corrected the specification and the code of the function or_sel_tree_with_checks.
  • Revision #3277 Sat 2011-11-12 12:03:27 +0200
    • Remove unused variable detected by GCC 4.6.1.
  • Revision #3276 Sat 2011-11-12 11:29:12 +0200
    • Fix MySQL Bug #12329653
      • In MariaDB, when running in ONLY_FULL_GROUP_BY mode, the server produced in incorrect error message that there is an aggregate function without GROUP BY, for artificially created MIN/MAX functions during subquery MIN/MAX optimization.
      • The fix introduces a way to distinguish between artifially created MIN/MAX functions as a result of a rewrite, and normal ones present in the query. The test for ONLY_FULL_GROUP_BY violation now tests in addition if a MIN/MAX function was part of a MIN/MAX subquery rewrite.
      • In order to be able to distinguish these MIN/MAX functions, the patch introduces an additional flag in Item_in_subselect::in_strategy - SUBS_STRATEGY_CHOSEN. This flag is set when the optimizer makes its final choice of a subuqery strategy. In order to make the choice consistent, access to Item_in_subselect::in_strategy is provided via new class methods.
    • Fix MySQL Bug #12329653
      • In MariaDB, when running in ONLY_FULL_GROUP_BY mode, the server produced in incorrect error message that there is an aggregate function without GROUP BY, for artificially created MIN/MAX functions during subquery MIN/MAX optimization.
      • The fix introduces a way to distinguish between artifially created MIN/MAX functions as a result of a rewrite, and normal ones present in the query. The test for ONLY_FULL_GROUP_BY violation now tests in addition if a MIN/MAX function was part of a MIN/MAX subquery rewrite.
      • In order to be able to distinguish these MIN/MAX functions, the patch introduces an additional flag in Item_in_subselect::in_strategy - SUBS_STRATEGY_CHOSEN. This flag is set when the optimizer makes its final choice of a subuqery strategy. In order to make the choice consistent, access to Item_in_subselect::in_strategy is provided via new class methods.
  • Revision #3275 Fri 2011-11-11 14:53:26 -0800
    • Fixed Bug #879871
    • The function add_ref_to_table_cond missed updating the value of join_tab->pre_idx_push_select_cond after having updated the value of join_tab->select->pre_idx_push_select_cond.
  • Revision #3274 [merge] Thu 2011-11-10 13:28:02 -0800
    • Merge of the maria-5.3-icp tree into the 5.3 tree
    • Revision #3256.1.16 [merge] Tue 2011-11-08 08:04:48 -0800
      • Merge.
    • Revision #3256.1.15 Mon 2011-11-07 23:30:03 +0400
      • Bug #887026: Wrong result with ICP, outer join, subquery in maria-5.3-icp
        • Do not push index condition if we're using a triggered ref access.
    • Revision #3256.1.14 [merge] Sun 2011-11-06 13:44:59 -0800
      • Merge.
    • Revision #3256.1.13 Sun 2011-11-06 01:23:03 -0700
      • Fixed Bug #886145
      • The bug happened because in some cases the function JOIN::exec did not save the value of TABLE::pre_idx_push_select_cond in TABLE::select->pre_idx_push_select_cond for the sort table.
      • Noticed and fixed a bug in the function make_cond_remainder that builds the remainder condition after extraction of an index pushdown condition from the where condition. The code erroneously assumed that the function make_cond_for_table left the value of ICP_COND_USES_INDEX_ONLY in sub-condition markers.
      • Adjusted many result files from the regression test suite after this fix .
    • Revision #3256.1.12 Fri 2011-11-04 05:39:45 -0700
      • Fixed Bug #885168
      • The call of the virtual function cancel_pushed_idx_cond in the code of the function test_if_skip_sort_order was misplaced when backporting the fix for MySQL Bug #58816
    • Revision #3256.1.11 [merge] Wed 2011-11-02 01:22:11 -0700
      • Merge.
    • Revision #3256.1.10 Tue 2011-11-01 07:00:55 -0700
      • Backported the fix and the test case for MySQL Bug #12822678 from the mysql-5.6 code line.
      • Fixed a bug in select_describe.
      • Adjusted results for affected test cases.
    • Revision #3256.1.9 Mon 2011-10-31 01:36:28 -0700
      • Fixed a compilation error.
    • Revision #3256.1.8 Mon 2011-10-31 01:13:12 -0700
      • Backported the test case for MySQL Bug #59843 from the mysql-5.6 code line.
      • (Failed to reproduce the bug in mariadb-5.3).
    • Revision #3256.1.7 Sun 2011-10-30 06:17:07 -0700
      • Backported the fix and the test case for MySQL Bug #59483 from the mysql-5.6 code line.
    • Revision #3256.1.6 Sun 2011-10-30 04:18:09 -0700
    • Revision #3256.1.5 Sun 2011-10-30 03:34:26 -0700
      • Backported the test case for MySQL Bug #59186 from mysql-5.6 code line.
      • The bug was fixed by the patch for Bug #694092 that was applied earlier to the mariadb-5.3 code.
    • Revision #3256.1.4 Sun 2011-10-30 02:37:10 -0700
    • Revision #3256.1.3 Sat 2011-10-29 15:36:24 -0700
      • Backported the fix and the test case for MySQL Bug #58816 from mysql-5.6 code line.
    • Revision #3256.1.2 [merge] Fri 2011-10-28 05:19:45 -0700
      • Merge.
    • Revision #3256.1.1 [merge] Fri 2011-10-28 04:07:11 -0700
  • Revision #3273 Mon 2011-11-07 16:39:02 +0400
    • Make subselect_extra_no_semijoin.test run the tests with semijoin=off,
    • update test results
  • Revision #3272 Fri 2011-11-04 12:04:12 +0200
    • Fixed that test doesn't abort if 'var' points to a deleted directory (common case when using --mem)
    • Better error message if --log-bin is used without --log-bin-index
  • Revision #3271 Fri 2011-11-04 10:14:25 +0200
    • Fixed Bug #884101 "Crash in check_table_is_closed with concurrent workload"
  • Revision #3270 Thu 2011-11-03 13:00:25 +0100
    • rename binlog_dbug_fsync_sleep -> debug_binlog_fsync_sleep
  • Revision #3269 Thu 2011-11-03 12:59:48 +0100
    • cast.test: use exact double, to be independent from compiler optimizations
  • Revision #3268 [merge] Wed 2011-11-02 22:06:22 +0400
    • Merge
    • Revision #3262.1.3 Wed 2011-11-02 22:05:08 +0400
      • Bug #878753: Assertion '0' failed in replace_where_subcondition with derived_merge
        • Remove the assert in replace_where_subcondition (the patch has explanation why)
  • Revision #3267 Wed 2011-11-02 20:01:50 +0400
    • Change the default @@optimizer_switch settings:
      • More test result updates (the errors are the same, the difference is that "at row X" became "at row Y" due to queries with semi-joins producing select results in different order)
  • Revision #3266 Wed 2011-11-02 19:52:11 +0400
    • Fix "unused variable addr" warning
  • Revision #3265 [merge] Wed 2011-11-02 19:37:26 +0400
    • Merge
    • Revision #3262.1.2 Wed 2011-11-02 19:36:08 +0400
      • Change the default @@optimizer_switch settings:
        • More test result updates
  • Revision #3264 [merge] Wed 2011-11-02 13:51:47 +0400
    • Merge
    • Revision #3262.1.1 Wed 2011-11-02 13:48:41 +0400
      • Change the default @@optimizer_switch settings:
        • semijoin=on
        • firstmatch=on
        • loosescan=on
  • Revision #3263 [merge] Wed 2011-11-02 10:05:07 +0200
    • Merge of Bug #872775 fix
      • Revision #3248.1.1 Tue 2011-11-01 17:42:52 +0200
        • Fix of Bug #872775
        • The problem was that merged views has its own nest_level numbering => when we compare nest levels we should take into considiration basis (i.e. 0 level), if it is different then nest levels are not comparable.
  • Revision #3262 Tue 2011-11-01 18:19:19 +0200
    • Fix Bug #833702
    • Analysis:
      • Equality propagation propagated the constant '7' into args[0] of the Item_in_optimizer that stands for the "< ANY" predicate. At the same the min/max subquery rewrite swapped the order of the left and right operands of the "<" predicate, but used Item_in_subselect::left_expr.
      • As a result, when the <ANY predicate is executed early in the execution phase as a contant condition, instead of a constant right (swapped) argument of the < predicate, there was a field (t3.a). This field had no data, since the whole predicate is considered constant, and it is evaluated before any tables are read. Having junk in the field row buffer produced wrong result
    • Solution:
      • Fix create_swap to pick the correct Item_in_optimizer left argument.
  • Revision #3261 Tue 2011-11-01 13:22:09 +0200
    • Fix of typo.
  • Revision #3260 Tue 2011-11-01 12:04:11 +0400
    • Bug #884631: Table elimination works 5.3 release builds even if turned off
      • Make table elimination to actually switch itself on/off in release builds.
  • Revision #3259 Mon 2011-10-31 15:07:43 +0400
    • Bug #882994: Crash in QUICK_RANGE_SELECT::reset with derived_with_keys
      • The bug was caused by the following scenario:
        • a quick select is created with get_quick_select_for_ref. The quick select refers to temporary (derived) table. It saves table->file, which refers to a ha_heap object.
        • When temp table is populated, ha_heap reaches max. size and is converted to a ha_myisam. However, quick->file remains pointing to where ha_heap was.
        • Attempt to use the quick select causes crash.
          • Fixed by introducing QUICK_SELECT_I::replace_handler(). Note that it will not work for index_merge quick selects. Which is fine, because these quick selects are never created for derived tables.
  • Revision #3258 Fri 2011-10-28 12:38:36 +0400
    • Let t/myisam_icp.test run include/icp_tests.inc with MRR/ICP turned ON (not OFF)
    • Fix the compile-time-default value of optimizer_switch printed by mysqld --help --defaults
  • Revision #3257 Fri 2011-10-28 11:23:30 +0400
    • Make innodb_no_mrricp.test to really run with MRR and ICP turned OFF.
  • Revision #3256 Thu 2011-10-27 12:03:33 -0700
    • Moved the test case for Bug #879939 to derived_view.test where it belongs to.
  • Revision #3255 [merge] Thu 2011-10-27 09:14:45 -0700
    • Merge.
    • Revision #3252.1.1 Thu 2011-10-27 08:32:24 -0700
      • Fixed Bug #874035
      • The function Item_direct_view_ref::fix_fields erroneously did not correct the value of the flag maybe_null when the view for which the item was being fixed happened to be an inner table of an outer join.
  • Revision #3254 Thu 2011-10-27 13:54:28 +0400
    • Bug #882472: subselect4.test fails in current 5.3
      • The problem was that the value of READ_RECORD::file was not updated when the underlying table was temporary and was converted from heap to myisam. Resolved by eliminating READ_RECORD::file, always use READ_RECORD::table->file
  • Revision #3253 Wed 2011-10-26 20:25:18 +0300
    • Fixed Bug #879939 "assertion in ha_maria::enable_indexes with derived_with_keys=on"
    • Honor unique/not unique when creating keys for internal tempory tables.
    • Added new variables to be used to limit how keys are created for internal temporary tables.
  • Revision #3252 Wed 2011-10-26 04:27:09 -0700
    • Fixed Bug #881449
    • The function SELECT_LEX::update_used_tables first must clean up all bitmaps to be recalculated for all tables that require it and only after this walk through on conditions attached to the tables to update these bitmaps.
  • Revision #3251 [merge] Wed 2011-10-26 10:58:40 +0400
    • Merge fix for Bug #877288
    • Revision #3249.1.1 Wed 2011-10-26 02:38:49 +0400
      • Bug #877288: Wrong result with semijoin + materialization + multipart key
        • when create_ref_for_key() is constructing a ref access for a table that's inside a SJ-Materialization nest, it may not use references to fields of tables that are unside the nest (because these fields will not yet have values when ref access will be used)
        • The check was performed in the first of create_ref_for_key's loops (the one which counts how many key parts are usable) but not in the second (the one which actually fills the TABLE_REF structure).
  • Revision #3250 Tue 2011-10-25 14:18:19 -0700
    • Fixed Bug #881318.
    • If a materialized derived table / view is empty then for this table the value of file->ref is 0. This was not taken into account by the function JOIN_CACHE::write_record_data. As a result a query using an empty materialized derived tables as inner tables of outer joins and IN subqueries in WHERE conditions could cause server crashes when the optimizer employed join caches and duplicate elimination for semi-joins.
  • Revision #3249 Mon 2011-10-24 12:54:28 -0700
    • Fixed Bug #880724
    • Do not create KEYUSEs for a materialized view over a constant table.
  • Revision #3248 Sun 2011-10-23 05:46:03 -0700
    • Fixed Bug #879882
    • This bug happened because the function Item_cond::eval_not_null_tables erroneously did not initialize the value of not_null_tables_cache.
  • Revision #3247 Sat 2011-10-22 07:19:43 -0700
    • Fixed Bug #878769
    • The method DsMrr_impl::dsmrr_init erroneously tried to get a KEY descriptor for key with number MAX_KEY. This caused valgrind complains.
  • Revision #3246 Sat 2011-10-22 00:14:27 -0700
    • Fixed Bug #874378
    • This bug happened for the queries over multi-table mergeable views because the bitmap TABLE::read_set of the underlying tables were not updated after the views had been merged into the query.
    • Now this bitmaps are updated properly.
    • Also the bitmap TABLE::merge_keys now is updated in prevention of future bugs.
  • Revision #3245 Thu 2011-10-20 08:02:31 -0700
  • Revision #3244 Thu 2011-10-20 04:59:20 -0700
    • Fixed Bug #878199
    • The function JOIN::drop_unused_derived_keys could erroneously set the value of REF::key to 0 for a joined materialized view/derived table in the case when no REF access to the table was used by the query execution plan. This could cause a crash of the server.
  • Revision #3243 [merge] Wed 2011-10-19 23:35:11 -0700
    • Merge.
    • Revision #3240.1.1 Wed 2011-10-19 23:28:37 -0700
      • Fixed Bug #877316
      • This bug happened due to incompleteness of the fix for Bug #872735: the occurrences of the fields in the conditions of correlated subqueries were not taken into account when recalculating covering keys bit maps.
  • Revision #3242 [merge] Wed 2011-10-19 21:01:42 +0200
    • merge 5.2
    • Revision #2732.46.11 [merge] Wed 2011-10-19 20:53:16 +0200
    • Revision #2732.46.10 Sun 2011-10-16 21:55:53 +0300
      • Fixed wrong info message for mysqld --general-log
      • Fixed wrong parameter type for --general-log. Now one can enable it with --general-log= 1 | true | on
      • Fixed that bool parameters can also take 'on' and 'off' as parameters. This is in line with the values assigned to them in mysqld.
  • Revision #3241 Tue 2011-10-18 22:50:17 +0300
    • Fix of building on Mac OS.
  • Revision #3240 [merge] Tue 2011-10-18 14:04:10 +0300
    • merge
    • Revision #3233.2.1 Tue 2011-10-18 13:44:12 +0300
      • Compiler warning about assigned but not used variables fixed.
  • Revision #3239 Mon 2011-10-17 03:42:56 -0700
    • Fixed a compiler warning.
  • Revision #3238 [merge] Mon 2011-10-17 01:20:16 -0700
    • Merge.
    • Revision #3235.1.1 Sun 2011-10-16 13:23:57 -0700
      • Fixed Bug #874006
      • This bug manifested itself with queries containing non-correlated IN subqueries over materialized views/derived tables.
      • The bug happened because the code of the function generate_derived_keys did not take into account that the function could be called twice when the optimizer was deciding whether in-exist transformation should be applied.
  • Revision #3237 Sun 2011-10-16 22:46:11 +0300
    • Remove extra MariaDB- from binary tar.gz file name
    • Print server version name to .err file on crash
  • Revision #3236 Fri 2011-10-14 17:51:16 +0200
    • In crash handler, output session value of the optimizer switch.
  • Revision #3235 [merge] Fri 2011-10-14 03:56:41 -0700
    • Merge.
    • Revision #3233.1.1 [merge] Fri 2011-10-14 00:11:50 -0700
      • Merge.
      • Revision #3232.1.1 Thu 2011-10-13 22:39:00 -0700
        • Fixed Bug #872735
        • This bug happened because the maps of covering keys for mergeable derived tables/views was not recalculated after the derived tables/vies had been merged into the main query.
  • Revision #3234 Fri 2011-10-14 12:41:20 +0200
    • update pbxt test results
  • Revision #3233 Thu 2011-10-13 13:44:50 +0200
    • Bug #817966 int_column IN (string_constant)
    • restore the status quo from before the microsecond patch
  • Revision #3232 Thu 2011-10-13 11:23:59 +0200
    • typo.
Content reproduced on this site is the property of its respective owners, and this content is not reviewed in advance by MariaDB. The views, information and opinions expressed by this content do not necessarily represent those of MariaDB or any other party.