Commit graph

416 commits

Author SHA1 Message Date
jimw@mysql.com
1d997477aa Merge mysql.com:/home/jimw/my/mysql-4.1-clean
into  mysql.com:/home/jimw/my/mysql-5.0-clean
2005-08-31 15:24:06 -07:00
jimw@mysql.com
0dc444ec4e Fix incorrect spellings of "dropped" in source and tests. (Bug #12828) 2005-08-30 12:24:37 -07:00
andrey@lmy004.
c9d9c74ac6 Merge ahristov@bk-internal.mysql.com:/home/bk/mysql-5.0
into lmy004.:/work/mysql-5.0-bug11904
2005-08-27 09:09:54 +02:00
andrey@lmy004.
7b1b3997a8 fix for bug #11904 (select statement, cursor, grouping wrong results) 2005-08-26 09:45:30 +02:00
monty@mishka.local
b90d7fe3b6 Merge bk-internal.mysql.com:/home/bk/mysql-5.0
into  mishka.local:/home/my/mysql-5.0
2005-08-25 09:40:40 +03:00
monty@mishka.local
f384e08277 Merge mishka.local:/home/my/mysql-4.1
into  mishka.local:/home/my/mysql-5.0
2005-08-25 06:55:48 +03:00
jimw@mysql.com
6964b7491e Merge mysql.com:/home/jimw/my/mysql-5.0-11680
into  mysql.com:/home/jimw/my/mysql-5.0-clean
2005-08-24 15:54:23 -07:00
jimw@mysql.com
cf5dd176c0 Fix build using --without-server. (Bug #11680) 2005-08-23 11:25:24 -07:00
timour@mysql.com
e040300393 WL#2486 - natural and using join according to SQL:2003
* Provide backwards compatibility extension to name resolution of
  coalesced columns. The patch allows such columns to be qualified
  with a table (and db) name, as it is in 4.1.
  Based on a patch from Monty.

* Adjusted tests accordingly to test both backwards compatible name
  resolution of qualified columns, and ANSI-style resolution of
  non-qualified columns.
  For this, each affected test has two versions - one with qualified
  columns, and one without.
2005-08-23 18:08:04 +03:00
evgen@moonbone.local
6d8bd17c3a Fix bug #11718 query with function, join and order by returns wrong type.
create_tmp_field_from_item() was creating tmp field without regard to
original field type of Item. This results in wrong type being reported to
client.

To create_tmp_field_from_item() added special handling for Items with 
DATE/TIME field types to preserve their type.
2005-08-17 23:53:12 +04:00
monty@mysql.com
1a6f16edd9 Merge bk-internal.mysql.com:/home/bk/mysql-5.0
into  mysql.com:/home/my/mysql-5.0
2005-08-15 18:35:48 +03:00
monty@mysql.com
df32f7d621 Save and clear run context before executing a stored function or trigger and restore it afterwards.
This allows us to use statement replication with functions and triggers
The following things are fixed with this patch:
- NOW() and automatic timestamps takes the value from the main event for functions and triggers (which allows these to replicate with statement level logging)
- No side effects for triggers or functions with auto-increment values(), last_insert_id(), rand() or found_rows()
- Triggers can't return result sets

Fixes bugs:
#12480: NOW() is not constant in a trigger
#12481: Using NOW() in a stored function breaks statement based replication
#12482: Triggers has side effects with auto_increment values
#11587: trigger causes lost connection error
2005-08-15 18:15:12 +03:00
timour@mysql.com
354ce1d024 Merge mysql.com:/home/timka/mysql/src/5.0-virgin
into  mysql.com:/home/timka/mysql/src/5.0-2486-merge
2005-08-12 19:27:54 +03:00
timour@mysql.com
a247282aa6 Implementation of WL#2486 -
"Process NATURAL and USING joins according to SQL:2003".

* Some of the main problems fixed by the patch:
  - in "select *" queries the * expanded correctly according to
    ANSI for arbitrary natural/using joins
  - natural/using joins are correctly transformed into JOIN ... ON
    for any number/nesting of the joins.
  - column references are correctly resolved against natural joins
    of any nesting and combined with arbitrary other joins.

* This patch also contains a fix for name resolution of items
  inside the ON condition of JOIN ... ON - in this case items must
  be resolved only against the JOIN operands. To support such
  'local' name resolution, the patch introduces a stack of
  name resolution contexts used at parse time.

NOTICE:
- This patch is not complete in the sense that
  - there are 2 test cases that still do not pass -
    one in join.test, one in select.test. Both are marked
    with a comment "TODO: WL#2486".
  - it does not include a new test specific for the task
2005-08-12 17:57:19 +03:00
acurtis@xiphis.org
b9476f7d50 Merge xiphis.org:/usr/home/antony/work2/mysql-4.1
into  xiphis.org:/usr/home/antony/work2/merge-5.0
2005-08-11 12:18:53 +01:00
konstantin@mysql.com
8392a814af A fix and a test case for Bug#12243 "MySQL Server crashes with 2
cursors (+ commit)" and Bug#11832 "Server crash with InnoDB + Cursors"
See comments to the changed files.
2005-08-10 18:36:13 +04:00
konstantin@mysql.com
3a73ef8a86 Fix coding style. 2005-08-10 17:45:42 +04:00
konstantin@mysql.com
f6306a8db1 A fix for Bug#11901 "mysql_stmt_attr_set CURSOR_TYPE_READ_ONLY join in
subqry order by server crash": failing DBUG_ASSERT(curr_join == this)
when opening a cursor.
Ensure that for top-level join curr_join == join (always), 
and thus fix the failing assert.
curr_join is a hack to ensure that uncacheable subqueries can be
re-evaluated safely, and should be never different from main join
in case of top-level join.
2005-08-10 12:25:26 +04:00
konstantin@mysql.com
043f77ccdf A fix and a test case for Bug#11909 "mysql_stmt_attr_set
CURSOR_TYPE_READ_ONLY nested queries corrupt result"
2005-08-08 19:24:56 +04:00
monty@mysql.com
987edeaa9b Fixed compiler warnings 2005-07-28 21:25:05 +03:00
pappa@c-450ae253.1238-1-64736c10.cust.bredbandsbolaget.se
6026054ead Merge mronstrom@bk-internal.mysql.com:/home/bk/mysql-4.1
into  c-450ae253.1238-1-64736c10.cust.bredbandsbolaget.se:/home/pappa/mysql-5.0
2005-07-21 01:29:57 -04:00
konstantin@mysql.com
21957c423e Implement MySQL framework to support consistent read views in
cursors. This should fix Bug#11813 when InnoDB part is in 
(tested with a draft patch).
The idea of the patch is that if a storage engine supports
consistent read views, we open one when open a cursor,
set is as the active view when fetch from the cursor, and close
together with cursor close.
2005-07-20 20:02:36 +04:00
georg@lmy002.wdf.sap.corp
dc0645f7cf Merge grichter@bk-internal.mysql.com:/home/bk/mysql-4.1
into lmy002.wdf.sap.corp:/home/georg/work/mysql/prod/mysql-4.1
2005-07-20 13:32:43 +02:00
georg@lmy002.wdf.sap.corp
3468c8485d cs fixes from last commit 2005-07-20 13:31:45 +02:00
jimw@mysql.com
2a06e5756e Merge bk-internal:/home/bk/mysql-5.0
into  mysql.com:/home/jimw/my/mysql-5.0-clean
2005-07-19 19:59:32 -07:00
jimw@mysql.com
63c6ece728 Cleanups after merge from 4.1. 2005-07-19 16:32:38 -07:00
konstantin@mysql.com
14344b658a A fix and a test case for Bug#10760 and complementary cleanups.
The idea of the patch
is that every cursor gets its own lock id for table level locking.
Thus cursors are protected from updates performed within the same 
connection. Additionally a list of transient (must be closed at
commit) cursors is maintained and all transient cursors are closed
when necessary. Lastly, this patch adds support for deadlock
timeouts to TLL locking when using cursors.
+ post-review fixes.
2005-07-19 22:21:12 +04:00
jimw@mysql.com
80c1c6b33f Merge mysql.com:/home/jimw/my/mysql-4.1-clean
into  mysql.com:/home/jimw/my/mysql-5.0-clean
2005-07-19 11:05:49 -07:00
georg@lmy002.wdf.sap.corp
3e1ae2633a fix for bug#12001 2005-07-19 17:31:18 +02:00
monty@mishka.local
2278e0319c Merge bk-internal.mysql.com:/home/bk/mysql-5.0
into  mishka.local:/home/my/mysql-5.0
2005-07-18 19:03:01 +03:00
reggie@linux.site
8f605428cb Merge rburnett@bk-internal.mysql.com:/home/bk/mysql-4.1
into  linux.site:/home/reggie/bk/bug7142
2005-07-18 08:03:59 -06:00
monty@mishka.local
78c65b5adc Cleanups during review
Changed defaults option --instance to --defaults-group-suffix
Changed option handling to allow --defaults-file, --defaults-extra-file and --defaults-group-suffix to be given in any order
Changed MYSQL_INSTANCE to MYSQL_GROUP_SUFFIX
mysql_print_defaults now understands --defaults-group-suffix
Remove usage of my_tempnam() (not safe function)
if( -> if ( and while( to while (
2005-07-18 15:33:18 +03:00
georg@lmy002.wdf.sap.corp
912fef706a cs fixes 2005-07-16 09:19:23 +02:00
georg@lmy002.wdf.sap.corp
02599bdf27 minor fix for restoring the previous characterset in
test_client_character_set
2005-07-15 17:05:00 +02:00
georg@lmy002.wdf.sap.corp
8c4cd0427f Fix for bug #11037.
When all rows are fetched subsequent calls to mysql_stmt_fetch return
now MYSQL_NO_DATA instead of errorcode 1.
2005-07-15 14:30:47 +02:00
tomas@poseidon.ndb.mysql.com
b144b920a0 Merge tulin@bk-internal.mysql.com:/home/bk/mysql-4.1
into poseidon.ndb.mysql.com:/home/tomas/mysql-4.1-new
2005-07-15 14:14:59 +02:00
konstantin@mysql.com
1c142ee631 Merge mysql.com:/opt/local/work/mysql-4.1-root
into  mysql.com:/opt/local/work/mysql-5.0-root
2005-07-14 20:02:34 +04:00
konstantin@mysql.com
a1270b65db A fix and a test case for Bug#11183 "mysql_stmt_reset() doesn't reset
information about error".
2005-07-14 20:02:33 +04:00
konstantin@mysql.com
3f28ad8eb7 Merge mysql.com:/opt/local/work/mysql-4.1-root
into  mysql.com:/opt/local/work/mysql-5.0-root
2005-07-14 20:02:32 +04:00
ramil@mysql.com
be233935cc fix for #11808 backported. 2005-07-14 20:19:27 +05:00
konstantin@mysql.com
509531421c Implement MarkM optimization request to avoid redundnat packet exchange
in cursors.
2005-07-14 15:27:24 +04:00
konstantin@mysql.com
62b8e6fdd1 A fix and a test case for Bug#9735.
No separate typecode for MEDIUMTEXT/LONGTEXT is added, as we
have no sound decision yet what typecodes and for what types are
sent by the server (aka what constitutes a distinct type in MySQL).
2005-07-14 15:13:23 +04:00
konstantin@mysql.com
e0b9e35484 Post-merge fixes. 2005-07-14 01:19:52 +04:00
ramil@mysql.com
6da9cf09c9 a fix (bug #11808: Test case 'mysql_client_test' fails in assert 'double_data == o_double_data') 2005-07-13 11:49:54 +05:00
reggie@linux.site
8a68788c39 Bug #7142 Show Fields from fails using Borland's dbExpress interface
The problem here is that columns that have an especially long type 
such as an enum type with many options would be longer than 40 chars
but the type column returned from show columns always was defined
as varchar(40).

This is fixed in 5.0 using info schema.
2005-07-12 08:35:30 -06:00
georg@lmy002.wdf.sap.corp
55d413252f changes after Bar's review: renamed CHARACTER_SET to MY_CHARSET_INFO 2005-07-12 10:58:21 +02:00
georg@lmy002.wdf.sap.corp
ceba4ee9cd New attempt after Bar's review
Added api function mysql_get_character_set_info which provides
information about the current client character set.
2005-07-12 10:31:43 +02:00
kent@mysql.com
8e3b393d5c Merge 2005-07-06 00:06:11 +02:00
kent@mysql.com
a7be42163a Makefile.am:
Added -I$(top_builddir)/include for searching
  generated header files, when builddir != srcdir
2005-07-05 23:24:48 +02:00
jimw@mysql.com
485f2c93c2 Merge mysql.com:/home/jimw/my/mysql-5.0-10214
into  mysql.com:/home/jimw/my/mysql-5.0-clean
2005-07-05 09:47:20 -07:00