Commit graph

682 commits

Author SHA1 Message Date
anozdrin/alik@ibm.
9fae9ef66f Patch for the following bugs:
- BUG#11986: Stored routines and triggers can fail if the code
    has a non-ascii symbol
  - BUG#16291: mysqldump corrupts string-constants with non-ascii-chars
  - BUG#19443: INFORMATION_SCHEMA does not support charsets properly
  - BUG#21249: Character set of SP-var can be ignored
  - BUG#25212: Character set of string constant is ignored (stored routines)
  - BUG#25221: Character set of string constant is ignored (triggers)

There were a few general problems that caused these bugs:
1. Character set information of the original (definition) query for views,
   triggers, stored routines and events was lost.
2. mysqldump output query in client character set, which can be
   inappropriate to encode definition-query.
3. INFORMATION_SCHEMA used strings with mixed encodings to display object
   definition;

1. No query-definition-character set.

In order to compile query into execution code, some extra data (such as
environment variables or the database character set) is used. The problem
here was that this context was not preserved. So, on the next load it can
differ from the original one, thus the result will be different.

The context contains the following data:
  - client character set;
  - connection collation (character set and collation);
  - collation of the owner database;

The fix is to store this context and use it each time we parse (compile)
and execute the object (stored routine, trigger, ...).

2. Wrong mysqldump-output.

The original query can contain several encodings (by means of character set
introducers). The problem here was that we tried to convert original query
to the mysqldump-client character set.

Moreover, we stored queries in different character sets for different
objects (views, for one, used UTF8, triggers used original character set).

The solution is
  - to store definition queries in the original character set;
  - to change SHOW CREATE statement to output definition query in the
    binary character set (i.e. without any conversion);
  - introduce SHOW CREATE TRIGGER statement;
  - to dump special statements to switch the context to the original one
    before dumping and restore it afterwards.

Note, in order to preserve the database collation at the creation time,
additional ALTER DATABASE might be used (to temporary switch the database
collation back to the original value). In this case, ALTER DATABASE
privilege will be required. This is a backward-incompatible change.

3. INFORMATION_SCHEMA showed non-UTF8 strings

The fix is to generate UTF8-query during the parsing, store it in the object
and show it in the INFORMATION_SCHEMA.

Basically, the idea is to create a copy of the original query convert it to
UTF8. Character set introducers are removed and all text literals are
converted to UTF8.

This UTF8 query is intended to provide user-readable output. It must not be
used to recreate the object.  Specialized SHOW CREATE statements should be
used for this.

The reason for this limitation is the following: the original query can
contain symbols from several character sets (by means of character set
introducers).

Example:

  - original query:
    CREATE VIEW v1 AS SELECT _cp1251 'Hello' AS c1;

  - UTF8 query (for INFORMATION_SCHEMA):
    CREATE VIEW v1 AS SELECT 'Hello' AS c1;
2007-06-28 21:34:54 +04:00
msvensson@pilot.(none)
bf5ced4035 Merge pilot.(none):/data/msvensson/mysql/mysql-5.0-maint
into  pilot.(none):/data/msvensson/mysql/mysql-5.1-new-maint
2007-06-28 11:31:09 +02:00
msvensson@pilot.(none)
a1a1dbc753 Bug#29361 mysqldump creates stray file when too long path name is passed
- Move the check of too long path to 'get_one_option'
2007-06-28 11:23:59 +02:00
tsmith@quadxeon.mysql.com
0ca0984f59 Merge tsmith@bk-internal.mysql.com:/home/bk/mysql-5.1
into  quadxeon.mysql.com:/benchmarks/ext3/TOSAVE/tsmith/bk/maint/jun05/51
2007-06-05 23:06:43 +02:00
tsmith@quadxeon.mysql.com
d2fe24d1ef Merge tsmith@bk-internal.mysql.com:/home/bk/mysql-5.0
into  quadxeon.mysql.com:/benchmarks/ext3/TOSAVE/tsmith/bk/maint/jun05/50
2007-06-05 23:04:40 +02:00
tsmith@quadxeon.mysql.com
4b93804592 Merge quadxeon.mysql.com:/benchmarks/ext3/TOSAVE/tsmith/bk/51
into  quadxeon.mysql.com:/benchmarks/ext3/TOSAVE/tsmith/bk/maint/jun05/51
2007-06-05 17:51:30 +02:00
ibabaev@bk-internal.mysql.com
d460dc700a Merge bk-internal.mysql.com:/data0/bk/mysql-5.1
into  bk-internal.mysql.com:/data0/bk/mysql-5.1-opt
2007-06-01 06:33:37 +02:00
tsmith@quadxeon.mysql.com
298e5002e3 mysqldump.c:
Fix harmless typo (caught thanks to warning)
2007-05-31 00:40:56 +02:00
tsmith@quadxeon.mysql.com
e97729a38f mysqldump.c:
Fix harmless typo (caught thanks to warning)
2007-05-31 00:37:41 +02:00
dkatz@damien-katzs-computer.local
6490419bb6 Merge damien-katzs-computer.local:/Users/dkatz/mysql50
into  damien-katzs-computer.local:/Users/dkatz/mysql51
2007-05-30 16:45:54 -04:00
ibabaev@bk-internal.mysql.com
faf19f9d60 Merge bk-internal.mysql.com:/data0/bk/mysql-5.1
into  bk-internal.mysql.com:/data0/bk/mysql-5.1-opt
2007-05-28 06:25:03 +02:00
ibabaev@bk-internal.mysql.com
040e46fc1c Merge bk-internal.mysql.com:/data0/bk/mysql-5.0
into  bk-internal.mysql.com:/data0/bk/mysql-5.0-opt
2007-05-28 00:05:38 +02:00
gshchepa/uchum@gleb.loc
fae737b426 Merge gleb.loc:/home/uchum/work/bk/mysql-5.0-opt
into  gleb.loc:/home/uchum/work/bk/mysql-5.1-opt
2007-05-28 00:22:44 +05:00
dkatz@damien-katzs-computer.local
4a7cdfc05d Bug #24733 RESET MASTER run before dump with --delete-master-logs
fixed by using flush logs, dumping, then doing PURGE MASTER LOGS TO 'binfile', instead
of deleting the log files at the beginning.
  
  NOTE: previously the delete-master-logs  would reset the log names back to
filename.00001. Now the trailing number doesn't get reset. This may need to be
documented.
2007-05-27 11:50:10 -04:00
gshchepa/uchum@gleb.loc
2ee30b0b7f Fixed bug #28522:
sometimes `mysqldump --hex-blob' overruned output buffer by '\0' byte.

The dump_table() function has been fixed to reserve 1 byte more for the
last '\0' byte of dumped string.
2007-05-25 17:24:17 +05:00
jani@a88-113-38-195.elisa-laajakaista.fi
fc3b3a0a86 Merge jamppa@bk-internal.mysql.com:/home/bk/mysql-5.1
into  a88-113-38-195.elisa-laajakaista.fi:/home/my/bk/mysql-5.1-marvel
2007-05-24 13:24:36 +03:00
msvensson@pilot.blaudden
e888128e88 Bug#28223: mysqldump --compact --routines restores from @OLD_SQL_MODE w/o ever setting it
- mysqldump generated output that set OLD_SQL_MODE twice, to different values
    (for triggers), or not at all (for routines) in some cases.
2007-05-16 10:14:29 +02:00
tnurnberg@blasphemy.mysql.com
a891692028 Bug#28223: mysqldump --compact --routines restores from @OLD_SQL_MODE w/o ever setting it
mysqldump generated output that set OLD_SQL_MODE twice, to different values
(for triggers), or not at all (for routines) in some cases.
---
Merge blasphemy.mysql.com:/home/tnurnberg/28223/50-28223
into  blasphemy.mysql.com:/home/tnurnberg/28223/51-28223
2007-05-14 09:02:40 +02:00
monty@mysql.com/narttu.mysql.fi
088e2395f1 WL#3817: Simplify string / memory area types and make things more consistent (first part)
The following type conversions was done:

- Changed byte to uchar
- Changed gptr to uchar*
- Change my_string to char *
- Change my_size_t to size_t
- Change size_s to size_t

Removed declaration of byte, gptr, my_string, my_size_t and size_s. 

Following function parameter changes was done:
- All string functions in mysys/strings was changed to use size_t
  instead of uint for string lengths.
- All read()/write() functions changed to use size_t (including vio).
- All protocoll functions changed to use size_t instead of uint
- Functions that used a pointer to a string length was changed to use size_t*
- Changed malloc(), free() and related functions from using gptr to use void *
  as this requires fewer casts in the code and is more in line with how the
  standard functions work.
- Added extra length argument to dirname_part() to return the length of the
  created string.
- Changed (at least) following functions to take uchar* as argument:
  - db_dump()
  - my_net_write()
  - net_write_command()
  - net_store_data()
  - DBUG_DUMP()
  - decimal2bin() & bin2decimal()
- Changed my_compress() and my_uncompress() to use size_t. Changed one
  argument to my_uncompress() from a pointer to a value as we only return
  one value (makes function easier to use).
- Changed type of 'pack_data' argument to packfrm() to avoid casts.
- Changed in readfrm() and writefrom(), ha_discover and handler::discover()
  the type for argument 'frmdata' to uchar** to avoid casts.
- Changed most Field functions to use uchar* instead of char* (reduced a lot of
  casts).
- Changed field->val_xxx(xxx, new_ptr) to take const pointers.

Other changes:
- Removed a lot of not needed casts
- Added a few new cast required by other changes
- Added some cast to my_multi_malloc() arguments for safety (as string lengths
  needs to be uint, not size_t).
- Fixed all calls to hash-get-key functions to use size_t*. (Needed to be done
  explicitely as this conflict was often hided by casting the function to
  hash_get_key).
- Changed some buffers to memory regions to uchar* to avoid casts.
- Changed some string lengths from uint to size_t.
- Changed field->ptr to be uchar* instead of char*. This allowed us to
  get rid of a lot of casts.
- Some changes from true -> TRUE, false -> FALSE, unsigned char -> uchar
- Include zlib.h in some files as we needed declaration of crc32()
- Changed MY_FILE_ERROR to be (size_t) -1.
- Changed many variables to hold the result of my_read() / my_write() to be
  size_t. This was needed to properly detect errors (which are
  returned as (size_t) -1).
- Removed some very old VMS code
- Changed packfrm()/unpackfrm() to not be depending on uint size
  (portability fix)
- Removed windows specific code to restore cursor position as this
  causes slowdown on windows and we should not mix read() and pread()
  calls anyway as this is not thread safe. Updated function comment to
  reflect this. Changed function that depended on original behavior of
  my_pwrite() to itself restore the cursor position (one such case).
- Added some missing checking of return value of malloc().
- Changed definition of MOD_PAD_CHAR_TO_FULL_LENGTH to avoid 'long' overflow.
- Changed type of table_def::m_size from my_size_t to ulong to reflect that
  m_size is the number of elements in the array, not a string/memory
  length.
- Moved THD::max_row_length() to table.cc (as it's not depending on THD).
  Inlined max_row_length_blob() into this function.
- More function comments
- Fixed some compiler warnings when compiled without partitions.
- Removed setting of LEX_STRING() arguments in declaration (portability fix).
- Some trivial indentation/variable name changes.
- Some trivial code simplifications:
  - Replaced some calls to alloc_root + memcpy to use
    strmake_root()/strdup_root().
  - Changed some calls from memdup() to strmake() (Safety fix)
  - Simpler loops in client-simple.c
2007-05-10 12:59:39 +03:00
tnurnberg@mysql.com/blasphemy.mysql.com
205dfa4401 Bug#27293: mysqldump crashes when dumping procedure defined by different user
mysqldump didn't properly handle getting no data on
SHOW CREATE PROCEDURE.  If S/C/P fails (due to dumping
user's insufficient privileges on mysql.proc, say),
mysqldump will print a comment to that effect to the
output and return an error-code.  If the -f (force) option
is used, the dump will continue, otherwise, it will abort
right there and then.

Also fixes Bug#22761, "mysqldump reports no errors when using
--routines without mysql.proc privileges"
---
Merge mysql.com:/home/tnurnberg/27293/50-27293
into  mysql.com:/home/tnurnberg/27293/51-27293
---
Merge tnurnberg@bk-internal.mysql.com:/home/bk/mysql-5.1-maint
into  mysql.com:/home/tnurnberg/27293/51-27293
2007-04-30 12:32:57 +02:00
tnurnberg@mysql.com/blasphemy.mysql.com
ce1074f6fe Bug#27293: mysqldump crashes when dumping procedure defined by different user
mysqldump didn't properly handle getting no data on
SHOW CREATE PROCEDURE.  If S/C/P fails (due to dumping
user's insufficient privileges on mysql.proc, say),
mysqldump will print a comment to that effect to the
output and return an error-code.  If the -f (force) option
is used, the dump will continue, otherwise, it will abort
right there and then.

Also fixes Bug#22761, "mysqldump reports no errors when using
--routines without mysql.proc privileges"
---
Merge tnurnberg@bk-internal.mysql.com:/home/bk/mysql-5.0-maint
into  mysql.com:/home/tnurnberg/27293/50-27293
2007-04-30 11:30:07 +02:00
malff/marcsql@weblab.(none)
2d6d8e2abe Merge weblab.(none):/home/marcsql/TREE/mysql-5.1-base
into  weblab.(none):/home/marcsql/TREE/mysql-5.1-rt-merge
2007-04-20 15:31:41 -06:00
kostja@vajra.(none)
e0f0ba802f Merge bk-internal.mysql.com:/home/bk/mysql-5.1
into  vajra.(none):/opt/local/work/mysql-5.1-runtime
2007-04-14 18:31:43 -04:00
jani@ua141d10.elisa.omakaista.fi
335153121b Merge jamppa@bk-internal.mysql.com:/home/bk/mysql-5.0
into  ua141d10.elisa.omakaista.fi:/home/my/bk/mysql-5.0-marvel
2007-04-12 12:50:02 +03:00
jani@ua141d10.elisa.omakaista.fi
b4ba815967 Merge jamppa@bk-internal.mysql.com:/home/bk/mysql-5.1
into  ua141d10.elisa.omakaista.fi:/home/my/bk/mysql-5.1-marvel
2007-04-10 16:28:47 +03:00
Kristofer.Pettersson@naruto.
7d3c4c29da Merge naruto.:C:/cpp/bug26121/my51-bug26121
into  naruto.:C:/cpp/mysql-5.1-runtime
2007-04-07 21:03:35 +02:00
holyfoot/hf@hfmain.(none)
ce426dd622 Merge bk@192.168.21.1:mysql-5.1-opt
into  mysql.com:/d2/hf/mrg/mysql-5.1-opt
2007-04-07 14:59:53 +05:00
Kristofer.Pettersson@naruto.
1902786808 Bug#26121 mysqldump includes LOCK TABLES general_log WRITE
- Giving the directive '--all-databases' to mysqldump caused 
  an attempt to lock and dump log tables which don't support this
  operation.
- With this patch the log tables are excluded from the set of
  databases tables to dump.
2007-04-05 21:53:02 +02:00
gluh@mysql.com/eagle.(none)
2d47f0cb1b Bug#21432 Database/Table name limited to 64 bytes, not chars, problems with multi-byte 2007-04-03 16:13:27 +05:00
ramil/ram@ramil.myoffice.izhnet.ru
f5a24e5870 Merge mysql.com:/home/ram/work/b25993/b25993.5.0
into  mysql.com:/home/ram/work/b25993/b25993.5.1
2007-03-26 13:01:46 +05:00
ramil/ram@mysql.com/ramil.myoffice.izhnet.ru
74b3cdb02e Fix for bug #25993: mysqldump crashes with merge table and -c option
opt_complete_insert was improperly used by accident.
Use complete_insert flag instead.
2007-03-26 12:56:41 +05:00
dkatz/Damien@damiendev.
6a7ef1849a bug#26346
Fix to a memory leak found by a complier warning.
2007-03-23 19:30:25 -04:00
dkatz/Damien@damiendev.
8cb8bf0ed0 Merge damiendev.:C:/build/dev50
into  damiendev.:C:/build/mysql-5.1
2007-03-23 18:22:57 -04:00
dkatz/Damien@damiendev.
53ecf4207e bug#26346
Added some fixes for an existing memory leak and unitilialized variables, both caught by gcc.
2007-03-23 18:15:11 -04:00
tnurnberg@sin.intern.azundris.com
3260dfd324 Merge tnurnberg@bk-internal.mysql.com:/home/bk/mysql-5.1-marvel
into  sin.intern.azundris.com:/home/tnurnberg/26817/51-26817
2007-03-23 20:43:40 +01:00
tnurnberg@sin.intern.azundris.com
998190ac55 Merge sin.intern.azundris.com:/home/tnurnberg/26817/50-26817
into  sin.intern.azundris.com:/home/tnurnberg/26817/51-26817
2007-03-23 20:39:37 +01:00
tnurnberg@sin.intern.azundris.com
7c63826894 Bug #26817: mysqldump fails to backup database containing view with invalid definer
give some leeway on required permissions for SHOW FIELDS on views so
an unknonwn DEFINER will no longer break mysqldump
2007-03-23 19:24:03 +01:00
Damien@damiendev.
ef3bbc426c additional changes to merge fix for bug 26346 2007-03-22 20:36:58 -04:00
Damien@damiendev.
db6f8d8ff8 Merge damiendev.:C:/build/mysql-5.1/..\dev50
into  damiendev.:C:/build/mysql-5.1
2007-03-22 20:08:05 -04:00
Damien@damiendev.
0fc5ad1e91 Bug#26346: stack + buffer overrun in mysqldump
Fixes to buffer overlows from long command line args, and unchecked dyn_str return codes. Also light refactoring.
2007-03-22 13:35:29 -04:00
jamppa@bk-internal.mysql.com
d2838b5abe Merge bk-internal.mysql.com:/data0/bk/mysql-5.1
into  bk-internal.mysql.com:/data0/bk/mysql-5.1-marvel
2007-03-22 13:14:52 +01:00
jani@ua141d10.elisa.omakaista.fi
71c7035035 Added find_type_or_exit and find_bit_type_or_exit as wrappers
around the original functions. These will ensure that error
message is always in unique form, reduce code and print the
right alternatives automatically in an error case.
2007-03-19 11:19:51 +02:00
kroki/tomash@moonlight.home
6d8f6b5bfd BUG#16420: Events: timestamps become UTC
BUG#26429: SHOW CREATE EVENT is incorrect for an event that
           STARTS NOW()
BUG#26431: Impossible to re-create an event from backup if its
           STARTS clause is in the past
WL#3698: Events: execution in local time zone

The problem was that local times specified by the user in AT, STARTS
and ENDS of CREATE EVENT/ALTER EVENT statement were converted to UTC,
and the original time zone was forgotten.  This way, event scheduler
couldn't honor Daylight Saving Time shifts, and times shown to the
user were also in UTC.  Additionally, CREATE EVENT didn't allow times
in the past, thus preventing straightforward event restoration from
old backups.

This patch reworks event scheduler time computations, performing them
in the time zone associated with the event.  Also it allows times to
be in the past.

The patch adds time_zone column to mysql.event table.

NOTE: The patch is almost final, but the bug#9953 should be pushed
first.
2007-03-16 17:31:07 +03:00
monty@mysql.com/narttu.mysql.fi
f0ae3ce9b9 Fixed compiler warnings
Fixed compile-pentium64 scripts
Fixed wrong estimate of update_with_key_prefix in sql-bench
Merge bk-internal.mysql.com:/home/bk/mysql-5.1 into mysql.com:/home/my/mysql-5.1
Fixed unsafe define of uint4korr()
Fixed that --extern works with mysql-test-run.pl
Small trivial cleanups
This also fixes a bug in counting number of rows that are updated when we have many simultanous queries
Move all connection handling and command exectuion main loop from sql_parse.cc to sql_connection.cc
Split handle_one_connection() into reusable sub functions.
Split create_new_thread() into reusable sub functions.
Added thread_scheduler; Preliminary interface code for future thread_handling code.

Use 'my_thread_id' for internal thread id's
Make thr_alarm_kill() to depend on thread_id instead of thread
Make thr_abort_locks_for_thread() depend on thread_id instead of thread
In store_globals(), set my_thread_var->id to be thd->thread_id.
Use my_thread_var->id as basis for my_thread_name()
The above changes makes the connection we have between THD and threads more soft.

Added a lot of DBUG_PRINT() and DBUG_ASSERT() functions
Fixed compiler warnings
Fixed core dumps when running with --debug
Removed setting of signal masks (was never used)
Made event code call pthread_exit() (portability fix)
Fixed that event code doesn't call DBUG_xxx functions before my_thread_init() is called.
Made handling of thread_id and thd->variables.pseudo_thread_id uniform.
Removed one common 'not freed memory' warning from mysqltest
Fixed a couple of usage of not initialized warnings (unlikely cases)
Suppress compiler warnings from bdb and (for the moment) warnings from ndb
2007-02-23 13:13:55 +02:00
monty@mysql.com/narttu.mysql.fi
e5cc397f33 Fixed compiler warnings (for linux and win32 and win64)
Fixed a couple of usage of not initialized warnings (unlikely cases)
2007-02-22 16:59:57 +02:00
monty@mysql.com/narttu.mysql.fi
410fc81a72 After merge fixes
Removed a lot of compiler warnings
Removed not used variables, functions and labels
Initialize some variables that could be used unitialized (fatal bugs)
%ll -> %l
2007-01-29 01:47:35 +02:00
monty@narttu.mysql.fi
8a80e36ac3 Merge mysql.com:/home/my/mysql-5.0
into  mysql.com:/home/my/mysql-5.1
Merge of 'remove compiler warnings when using -Wshadow'
2007-01-27 03:46:45 +02:00
monty@mysql.com/narttu.mysql.fi
a04157fbb3 Merge bk-internal.mysql.com:/home/bk/mysql-5.0
into  mysql.com:/home/my/mysql-5.0
2007-01-22 14:04:40 +02:00
kent@kent-amd64.(none)
be15e3bc15 Merge mysql.com:/home/kent/bk/main/mysql-5.0
into  mysql.com:/home/kent/bk/main/mysql-5.1
2006-12-23 20:20:40 +01:00
kent@mysql.com/kent-amd64.(none)
226a5c833f Many files:
Changed header to GPL version 2 only
2006-12-23 20:17:15 +01:00
monty@mysql.com/narttu.mysql.fi
88dd873de0 Fixed compiler warnings detected by option -Wshadow and -Wunused:
- Removed not used variables and functions
- Added #ifdef around code that is not used
- Renamed variables and functions to avoid conflicts
- Removed some not used arguments

Fixed some class/struct warnings in ndb
Added define IS_LONGDATA() to simplify code in libmysql.c

I did run gcov on the changes and added 'purecov' comments on almost all lines that was not just variable name changes
2006-12-15 00:51:37 +02:00
baker@bk-internal.mysql.com
dbe5f0acc5 Merge bk-internal.mysql.com:/data0/bk/mysql-5.1
into  bk-internal.mysql.com:/data0/bk/mysql-5.1-arch
2006-12-03 21:19:35 +01:00
brian@zim.(none)
31d67280f7 This finishes the work (someone) started to remove FIELD_ types and use the Enum MYSQL types. The second part to this is to actually deprecate the FIELD defines in mysql_com.h 2006-12-01 17:26:52 -08:00
mskold/marty@linux.site
6f0e7a2631 Merge mysql.com:/windows/Linux_space/MySQL/mysql-5.1
into  mysql.com:/windows/Linux_space/MySQL/mysql-5.1-new-ndb
2006-12-01 21:12:13 +01:00
monty@mysql.com/narttu.mysql.fi
601e6f4b2a Fixed compiler warnings
Don't assert if my_thread_end() is called twice (common case)
2006-11-30 21:56:03 +02:00
monty@mysql.com/narttu.mysql.fi
3d40956039 Fixed portability issue in my_thr_init.c (was added in my last push)
Fixed compiler warnings (detected by VC++):
- Removed not used variables
- Added casts
- Fixed wrong assignments to bool
- Fixed wrong calls with bool arguments
- Added missing argument to store(longlong), which caused wrong store method to be called.
2006-11-30 18:25:05 +02:00
mskold/marty@linux.site
d7e375680a Merge mysql.com:/windows/Linux_space/MySQL/mysql-5.1
into  mysql.com:/windows/Linux_space/MySQL/mysql-5.1-new-ndb
2006-11-30 15:31:20 +01:00
monty@mysql.com/narttu.mysql.fi
3a35c30027 Fixed compiler warnings (Mostly VC++):
- Removed not used variables
- Changed some ulong parameters/variables to ulonglong (possible serious bug)
- Added casts to get rid of safe assignment from longlong to long (and similar)
- Added casts to function parameters
- Fixed signed/unsigned compares
- Added some constructores to structures
- Removed some not portable constructs

Better fix for bug Bug #21428 "skipped 9 bytes from file: socket (3)" on "mysqladmin shutdown"
(Added new parameter to net_clear() to define when we want the communication buffer to be emptied)
2006-11-30 03:40:42 +02:00
monty@mysql.com/nosik.monty.fi
0e149b7170 Removed compiler warnings
Ensure that my_size_t is always unsigned (to get predictiable results from system to system)
Removed some %lld, as these are not portable
2006-11-27 18:16:08 +02:00
monty@mysql.com/nosik.monty.fi
fa81a82e7f Fixed a LOT of compiler warnings
Added missing DBUG_RETURN statements (in mysqldump.c)
Added missing enums
Fixed a lot of wrong DBUG_PRINT() statements, some of which could cause crashes
Removed usage of %lld and %p in printf strings as these are not portable or produces different results on different systems.
2006-11-27 01:47:38 +02:00
monty@mysql.com/nosik.monty.fi
fb9bb62b1e Added some missing DBUG_RETURN
Fixed that --valgrind works again with mysql-test-run.sh
Extended error messages when loosing connection during mysql_real_connect()
2006-11-23 16:41:21 +02:00
monty@nosik.monty.fi
89570bf966 Merge mysql.com:/home/my/mysql-5.0
into  mysql.com:/home/my/mysql-5.1
2006-11-22 14:11:36 +02:00
bar@mysql.com/bar.intranet.mysql.r18.ru
fb419c4241 BUG#13926: --order-by-primary fails if PKEY contains quote character.
Backporting from 5.0
2006-11-21 11:09:33 +04:00
monty@mysql.com/nosik.monty.fi
e825879800 Remove compiler warnings
(Mostly in DBUG_PRINT() and unused arguments)
Fixed bug in query cache when used with traceing (--with-debug)
Fixed memory leak in mysqldump
Removed warnings from mysqltest scripts (replaced -- with #)
2006-11-20 22:42:06 +02:00
mskold/marty@linux.site
6ad1b4f92c Merge mysql.com:/windows/Linux_space/MySQL/mysql-5.1
into  mysql.com:/windows/Linux_space/MySQL/mysql-5.1-new-ndb
2006-11-10 11:38:54 +01:00
stewart@willster.(none)
8f3ac043e8 Merge willster.(none):/home/stewart/Documents/MySQL/5.1/ndb
into  willster.(none):/home/stewart/Documents/MySQL/5.1/bug20839
2006-10-26 21:29:27 +10:00
msvensson@neptunus.(none)
e8881843a9 Merge neptunus.(none):/home/msvensson/mysql/mysql-5.0-maint
into  neptunus.(none):/home/msvensson/mysql/mysql-5.1-new-maint
2006-10-24 15:46:54 +02:00
msvensson@neptunus.(none)
26183402d1 Use same type for local variables as arguments, avoid compile error on NetWare 2006-10-24 13:52:50 +02:00
stewart@willster.(none)
910e4d974c BUG#20839 Illegal error code: 155 returned downgrading from 5.1.12-> 5.1.11
post-review fixups - magnus suggested creating dynstr_trunc instead of doing
it manually.
2006-10-20 22:47:28 +10:00
msvensson@neptunus.(none)
b11dee73ca Backport test cases fixes from 5.0 2006-10-19 10:54:23 +02:00
iggy@rolltop.ignatz42.dyndns.org
2ec5a57ff4 Merge rolltop.ignatz42.dyndns.org:/mnt/storeage/bug19745/my51-bug19745
into  rolltop.ignatz42.dyndns.org:/mnt/storeage/mysql-5.1-maint
2006-10-18 19:28:37 -04:00
iggy@rolltop.ignatz42.dyndns.org
39bda9e3cf Merge rolltop.ignatz42.dyndns.org:/mnt/storeage/bug19745/my50-bug19745
into  rolltop.ignatz42.dyndns.org:/mnt/storeage/mysql-5.0-maint
2006-10-18 19:27:14 -04:00
iggy@rolltop.ignatz42.dyndns.org
b61c3a7361 Merge rolltop.ignatz42.dyndns.org:/mnt/storeage/bug19745/my50-bug19745
into  rolltop.ignatz42.dyndns.org:/mnt/storeage/bug19745/my51-bug19745
2006-10-18 18:48:02 -04:00
iggy@rolltop.ignatz42.dyndns.org
3c31c84200 Bug#19745: mysqldump --xml produces invalid xml
The mysqldump command with both the --xml and --hex-blob options will output blob data encoded as hexBinary.  
The proper XML datatype is xs:hexBinary.  
The correct XML datatype is specified be setting the xsi_type attribute equal to xs:hexBinary for each encoded element.
2006-10-18 18:43:51 -04:00
cmiller@zippy.cornsilk.net
184467a2cc Merge bk-internal.mysql.com:/home/bk/mysql-5.1
into  zippy.cornsilk.net:/home/cmiller/work/mysql/mysql-5.1-maint
2006-10-17 11:23:07 -04:00
stewart@willster.(none)
49124e987c BUG#20839 Illegal error code: 155 returned downgrading from 5.1.12-> 5.1.11
post-review fixes.

Magnus suggested use of DYNAMIC_STRING instead of futzing with c strings.
also making usage of TABLEs clearer in store_schema_partitions_record.
2006-10-17 01:02:12 +10:00
stewart@willster.(none)
c1a8b8daa7 BUG#20839 Illegal error code: 155 returned downgrading from 5.1.12-> 5.1.11
Post review fix:
Magnus suggested making sure that new mysqldump still worked flawlessly
with old servers.
2006-10-17 00:15:58 +10:00
jonas@perch.ndb.mysql.com
e600a3d394 Merge perch.ndb.mysql.com:/home/jonas/src/mysql-5.1
into  perch.ndb.mysql.com:/home/jonas/src/mysql-5.1-new-ndb
2006-10-10 11:25:24 +02:00
stewart@willster.(none)
78f976d78e BUG#20839 Illegal error code: 155 returned downgrading from 5.1.12-> 5.1.11
Update mysqldump to dump the needed tablespaces to create the tables
for either the dbs or tables we're dumping.

With --all-tablespaces, we still dump everything.
2006-10-10 00:03:46 +10:00
iggy@rolltop.ignatz42.dyndns.org
8280c6baaa Merge rolltop.ignatz42.dyndns.org:/mnt/storeage/bug19660/my41-bug19660
into  rolltop.ignatz42.dyndns.org:/mnt/storeage/mysql-4.1-maint
2006-10-04 16:46:00 -04:00
iggy@rolltop.ignatz42.dyndns.org
5ed44ed09f Merge rolltop.ignatz42.dyndns.org:/mnt/storeage/bug19660/my50-bug19660
into  rolltop.ignatz42.dyndns.org:/mnt/storeage/mysql-5.0-maint
2006-10-04 16:44:51 -04:00
iggy@rolltop.ignatz42.dyndns.org
6ff8998d3c Merge rolltop.ignatz42.dyndns.org:/mnt/storeage/bug19660/my51-bug19660
into  rolltop.ignatz42.dyndns.org:/mnt/storeage/mysql-5.1-maint
2006-10-04 16:41:45 -04:00
iggy@rolltop.ignatz42.dyndns.org
9977eea685 Merge rolltop.ignatz42.dyndns.org:/mnt/storeage/bug19660/my50-bug19660
into  rolltop.ignatz42.dyndns.org:/mnt/storeage/bug19660/my51-bug19660
2006-10-04 15:34:03 -04:00
iggy@rolltop.ignatz42.dyndns.org
71ace9598d Merge rolltop.ignatz42.dyndns.org:/mnt/storeage/bug19660/my41-bug19660
into  rolltop.ignatz42.dyndns.org:/mnt/storeage/bug19660/my50-bug19660
2006-10-04 15:31:14 -04:00
stewart@willster.(none)
276aaa2164 BUG#20809 mysqldump does not backup TS and LG information correctly
restore of the dump (ndb_dd_dump test) was failing for probably a merge problem. fixed now.
2006-10-05 00:56:06 +10:00
iggy@rolltop.ignatz42.dyndns.org
728588da38 Bug#19660 mysqldump --single-transaction should be with CONSISTENT SNAPSHOT 2006-10-03 11:26:50 -04:00
lars/lthalmann@dl145k.mysql.com
60e178bb73 Merge lthalmann@bk-internal.mysql.com:/home/bk/mysql-5.1
into  mysql.com:/users/lthalmann/bkroot/mysql-5.1
2006-09-23 08:45:26 +02:00
lars/lthalmann@dl145j.mysql.com
57a74ea4af Merge mysql.com:/users/lthalmann/bkroot/mysql-5.1-new-rpl
into  mysql.com:/users/lthalmann/bk/MERGE/mysql-5.1-merge
2006-09-21 00:23:20 +02:00
lars/lthalmann@mysql.com/dl145j.mysql.com
d20e326504 Merge mysql.com:/users/lthalmann/bkroot/mysql-5.0-rpl
into  mysql.com:/users/lthalmann/bk/MERGE/mysql-5.0-merge
2006-09-21 00:05:56 +02:00
stewart@willster.(none)
e7a1495f22 Merge willster.(none):/home/stewart/Documents/MySQL/5.1/ndb
into  willster.(none):/home/stewart/Documents/MySQL/5.1/bug20809
2006-09-20 17:23:46 +10:00
stewart@willster.(none)
6ff9664d46 Merge ssmith@bk-internal.mysql.com:/home/bk/mysql-5.1-ndb
into  willster.(none):/home/stewart/Documents/MySQL/5.1/bug20073
2006-09-19 18:36:18 +10:00
stewart@willster.(none)
40dffeba03 BUG#20809 mysqldump does not backup TS and LG information correctly.
We were not parsing the EXTRA field to get UNDO_BUFFER_SIZE for the
CREATE LOGFILE GROUP statement in the dump.
2006-09-19 17:07:21 +10:00
stewart@willster.(none)
49eb41e09d BUG#20073 information_schema.FILES for UNDO LOG give incorrect EXTENT_SIZE, FREE_EXTENTS,
Change things around so that we add a row for each log file group that lists
the free space for that log file group.
2006-09-19 01:44:32 +10:00
lars/lthalmann@dl145j.mysql.com
a3adcfe52d Merge mysql.com:/users/lthalmann/bkroot/mysql-5.1-new-rpl
into  mysql.com:/users/lthalmann/bk/MERGE/mysql-5.1-merge
2006-09-15 01:46:47 +02:00
lars/lthalmann@mysql.com/dl145j.mysql.com
2840596e10 Merge mysql.com:/users/lthalmann/bkroot/mysql-5.0-rpl
into  mysql.com:/users/lthalmann/bk/MERGE/mysql-5.0-merge
2006-09-15 01:26:28 +02:00
iggy@rolltop.ignatz42.dyndns.org
453c5c5aa8 Merge rolltop.ignatz42.dyndns.org:/mnt/storeage/bug21424/my50-bug21424
into  rolltop.ignatz42.dyndns.org:/mnt/storeage/bug21424/my51-bug21424
2006-09-14 14:57:11 -04:00
iggy@rolltop.ignatz42.dyndns.org
4fa6c8c776 Bug#21424 mysqldump failing to export/import views.
Dumps are created for the tables in each specified database then for the views in each specified database. This bug occurs when any database's views depend on the mysql database's table data while being restored. 
Added command line option --flush-privileges to the mysqldump utility which causes a FLUSH PRIVILIGES statement to be written to the dump after the mysql database.
2006-09-14 14:56:14 -04:00
msvensson@neptunus.(none)
5a6cee9e1c Merge neptunus.(none):/home/msvensson/mysql/tmp_merge
into  neptunus.(none):/home/msvensson/mysql/mysql-5.1-new-maint
2006-09-12 15:38:02 +02:00
lars/lthalmann@dl145k.mysql.com
a1c70022f2 Merge mysql.com:/users/lthalmann/bk/MERGE/mysql-5.0-merge
into  mysql.com:/users/lthalmann/bk/MERGE/mysql-5.1-merge
2006-09-11 17:14:40 +02:00
lars/lthalmann@mysql.com/dl145j.mysql.com
4c467cc438 Merge mysql.com:/users/lthalmann/bkroot/mysql-5.0-rpl
into  mysql.com:/users/lthalmann/bk/MERGE/mysql-5.0-merge
2006-09-11 13:17:51 +02:00
msvensson@neptunus.(none)
8f378e0f3a Fix problem with windows where stderr is not flushed until end of program. 2006-09-01 13:53:43 +02:00
jimw@rama.(none)
4d29dd1f3b Merge rama.(none):/home/jimw/my/mysql-5.0-clean
into  rama.(none):/home/jimw/my/mysql-5.1-clean

mysqldump.result is wrong, will need to be cleaned up.
2006-08-31 21:02:17 -07:00
jimw@rama.(none)
bd2825f5bb Restore bug fix lost in merge of client/mysqldump.c, and clean up mysqldump.test
so that 4.1 and 5.0 tests are all in the right place and no tests are duplicated.
2006-08-31 20:53:34 -07:00
jimw@rama.(none)
5884eea9a3 Resolve conflicts 2006-08-31 18:24:37 -07:00
iggy@rolltop.ignatz42.dyndns.org
76bf7c81ae Merge rolltop.ignatz42.dyndns.org:/mnt/storeage/mysql-5.0-maint_21527
into  rolltop.ignatz42.dyndns.org:/mnt/storeage/mysql-5.1-new-maint_21527
2006-08-28 20:41:22 -04:00
iggy@rolltop.ignatz42.dyndns.org
bfe86ca448 Bug #21527 mysqldump incorrectly tries to LOCK TABLES on the information_schema database.
init_dumping now accepts a function pointer to the table or view specific init_dumping function.  This allows both tables and views to use the init_dumping function.
2006-08-28 17:48:06 -04:00
jimw@rama.(none)
abc148000d Bug #21288: mysqldump segmentation fault when using --where
The problem was that the error handling was using a too-small buffer to
  print the error message generated. We fix this by not using a buffer at
  all, but by using fprintf() directly. There were also some problems with
  the error handling in table dumping that was exposed by this fix that were
  also corrected.
2006-08-17 14:09:24 -07:00
kostja@bodhi.local
5dfdc8bfce Manual merge 5.0->5.1. Post-merge fixes. 2006-08-14 13:27:11 +04:00
kostja@bodhi.local
04c97488f9 Merge bodhi.local:/opt/local/work/tmp_merge
into  bodhi.local:/opt/local/work/mysql-5.1-runtime-merge
2006-08-12 21:06:51 +04:00
msvensson@neptunus.(none)
10a7b8cedf Merge neptunus.(none):/home/msvensson/mysql/mysql-5.0
into  neptunus.(none):/home/msvensson/mysql/mysql-5.0-maint
2006-08-03 12:11:07 +02:00
msvensson@neptunus.(none)
61c5d97309 Remove double error printout in mysqldump 2006-08-03 12:09:22 +02:00
msvensson@neptunus.(none)
743948404a Merge neptunus.(none):/home/msvensson/mysql/my50-m-bug21215
into  neptunus.(none):/home/msvensson/mysql/mysql-5.0
2006-08-03 11:48:08 +02:00
tsmith@maint1.mysql.com
242ed711d2 5.0 -> 5.1 manual merge, part 1 of 3 (or more?) 2006-08-03 10:04:25 +02:00
grog@eucla.lemis.com
90c9c72605 BUG#13926: --order-by-primary fails if PKEY contains quote character.
Quote PKEY.
2006-08-02 11:26:08 +09:30
grog@eucla.lemis.com
8597ebaed0 mysqldump.c:
Tidy up style: no space before = or +=.
2006-08-02 10:48:47 +09:30
msvensson@neptunus.(none)
31be565d2e Merge neptunus.(none):/home/msvensson/mysql/mysql-5.0
into  neptunus.(none):/home/msvensson/mysql/mysql-5.0-maint
2006-08-01 20:24:30 +02:00
jimw@rama.(none)
f7e19b40f3 Merge rama.(none):/home/jimw/my/tmp_merge
into  rama.(none):/home/jimw/my/mysql-5.1-clean
2006-07-28 15:51:48 -07:00
msvensson@neptunus.(none)
c84cdbf40b Bug#21215 mysqldump creating incomplete backups without warning
- Add call to 'safe_exit' function when db query fails.
2006-07-24 13:10:24 +02:00
msvensson@neptunus.(none)
9f78d779e3 Don't close connection to mysql before 'safe_exit', that is done in 'safe_exit' if it decides to exit. 2006-07-24 12:48:02 +02:00
msvensson@neptunus.(none)
c2e2ebb1a7 Remove double printout of mysqldump in error message 2006-07-24 12:43:35 +02:00
msvensson@neptunus.(none)
0ab8948c99 Replace sock -> mysql 2006-07-24 12:00:44 +02:00
msvensson@neptunus.(none)
b450438c8b Change tFlag and dFlag into human readable format
tFlag => opt_no_create_info
 dFlag => opt_no_data
2006-07-24 11:56:01 +02:00
msvensson@neptunus.(none)
6c12e990b2 Add function verbose_msg 2006-07-24 11:51:52 +02:00
msvensson@neptunus.(none)
3aa99c062f Bug#10877 mysqldump should use consistent last line
- Add printout in write_footer to tell that mysqldump has completed.
   Ex: -- Dump completed 2006-07-24  8:55:05
2006-07-24 10:56:33 +02:00
tnurnberg@salvation.intern.azundris.com
199bb148fd Merge salvation.intern.azundris.com:/home/tnurnberg/mysql-5.0-release
into  salvation.intern.azundris.com:/home/tnurnberg/work/mysql-5.0-merge
2006-07-19 14:12:30 +02:00
iggy@rolltop.ignatz42.dyndns.org
ad12809f35 Bug# 20221- Dumping of multiple databases containing view(s) yields maleformed dumps. 2006-07-17 18:07:08 -04:00
igreenhoe/greenman@anubis.greendragongames.com
9beb95f0ed Merge igreenhoe@bk-internal.mysql.com:/home/bk/mysql-5.0
into  anubis.greendragongames.com:/home/greenman/workspace-mysql/mysql/merge-4.1_2_5.0
2006-07-14 06:52:25 -07:00
tnurnberg@mysql.com/salvation.intern.azundris.com
00ec3973f7 Bug#21014: Segmentation fault of mysqldump on view
mysqldump did not select the correct database before trying to dump
views from it. this resulted in an empty result set, which in turn
startled mysql-dump into a core-dump.  this only happened for views,
not for tables, and was only visible with multiple databases that
weren't by sheer luck in the order mysqldump required, anyway. this
fixes by selecting the correct database before dumping views; it also
catches the empty set-condition if it should occur for other reasons.
2006-07-14 12:50:00 +02:00
igreenhoe/greenman@anubis.greendragongames.com
abb75129f8 4.1 -> 5.0 merge 2006-07-13 16:35:25 -07:00
tnurnberg@mysql.com/salvation.intern.azundris.com
4316f715d3 Bug#21014: Segmentation fault of mysqldump on view
mysqldump did not select the correct database before trying to dump
views from it. this resulted in an empty result set, which in turn
startled mysql-dump into a core-dump.  this only happened for views,
not for tables, and was only visible with multiple databases that
weren't by sheer luck in the order mysqldump required, anyway. this
fixes by selecting the correct database before dumping views; it also
catches the empty set-condition if it should occur for other reasons.
2006-07-14 01:25:13 +02:00
cmiller@zippy.(none)
6110a83a0e Merge zippy.(none):/home/cmiller/work/mysql/merge/mysql-5.0
into  zippy.(none):/home/cmiller/work/mysql/merge/mysql-5.1
2006-07-03 11:35:58 -04:00
tnurnberg@mysql.com
d5ff4f6882 Merge bk-internal.mysql.com:/home/bk/mysql-5.0-maint
into  mysql.com:/home/tnurnberg/mysql-5.0-maint-18462
2006-06-26 16:15:41 +02:00
lars@mysql.com
6b8c196584 Merge mysql.com:/users/lthalmann/bk/MERGE/mysql-5.0-merge
into  mysql.com:/users/lthalmann/bk/MERGE/mysql-5.1-merge
2006-06-21 14:14:37 +02:00
igreenhoe@mysql.com
85d130c58b Fix for bug #15977 (switch ordering of DISABLE KEYS/LOCK TABLE in mysqldump) 2006-06-21 00:12:23 -07:00
cmiller@zippy.(none)
deca07bdcc Merge bk-internal.mysql.com:/home/bk/mysql-5.0
into  zippy.(none):/home/cmiller/work/mysql/mysql-5.0-maint
2006-06-20 17:17:04 -04:00
lars@mysql.com
5937422a53 Merge mysql.com:/users/lthalmann/bkroot/mysql-5.0-rpl
into  mysql.com:/users/lthalmann/bk/MERGE/mysql-5.0-merge
2006-06-19 12:09:24 +02:00
tnurnberg@mysql.com
2b613e4ce7 Merge bk-internal.mysql.com:/home/bk/mysql-5.0-maint
into  mysql.com:/home/mysql-5.0-maint-17371
2006-06-12 02:46:26 +02:00
igor@rurik.mysql.com
950a000503 Fixed some problems for Windows build 2006-06-06 09:59:45 -07:00
tnurnberg@mysql.com
a717c68739 Merge bk-internal.mysql.com:/home/bk/mysql-5.0-maint
into  mysql.com:/home/mysql-5.0-maint-18462
2006-06-01 07:11:00 +02:00
tnurnberg@mysql.com
8c24373668 Bug#18462: mysqldump does not dump view structures correctly
(The above problem only occurs with -T -- create a separate file for
each table / view.) This ChangeSet results in correct output of view-
information while omitting the information for the view's stand-in
table. The rationale is that with -T, the user is likely interested
in transferring part of a database, not the db in its entirety (that
would be difficult as replay order is obscure, the files being named
for the table/view they contain rather than getting a sequence number).
2006-05-31 13:36:28 +02:00
jani@a193-229-222-105.elisa-laajakaista.fi
c81b4c01bf Merge a193-229-222-105.elisa-laajakaista.fi:/home/my/bk/mysql-5.0
into  a193-229-222-105.elisa-laajakaista.fi:/home/my/bk/mysql-5.1-new
2006-05-30 16:07:49 +03:00
tnurnberg@mysql.com
c7ae355d89 Bug#17371: Unable to dump a schema with invalid views
'show create' works even on views that are short of a base-table (this
throw a warning though, like you would expect). Unfortunately, this is
not what mysqldump uses; it creates stand-in tables and hence requests
'show fields' on the view which fails with missing base-tables.  The
--force option prevents the dump from stopping at this point; furthermore
this patch dumps a comment showing create for the offending view for
better diagnostics. This solution was confirmed by submitter as solving
their/clients' problem. Problem might become non-issue once mysqldump no
longer creates stand-in tables.
2006-05-30 14:49:05 +02:00
ramil@mysql.com
8436973fda after merge fix. 2006-05-29 12:32:08 +05:00
ramil@mysql.com
6b2ab800c9 manual merge 2006-05-29 11:17:38 +05:00
grog@mysql.com
1f86b3f100 BUG#17201: Improve handling of views. 2006-05-25 17:30:28 +09:30
ramil@mysql.com
13baf7575f Fix for bug #18536: mysqldump does not maintain table orders as per --tables option 2006-05-19 16:21:32 +05:00
jani@ua141d10.elisa.omakaista.fi
083f8455c7 Merge ua141d10.elisa.omakaista.fi:/home/my/bk/mysql-5.0
into  ua141d10.elisa.omakaista.fi:/home/my/bk/mysql-5.1-new
2006-05-09 20:50:29 +03:00
mskold@mysql.com
cb696feb0e Corrected include path to work under Windows 2006-04-26 17:00:58 +02:00
mskold@mysql.com
e95e6ddcb4 Fix for Bug #17840 mysqldump should not dump tables in database cluster, reuse existing define 2006-04-24 15:50:05 +02:00
mskold@mysql.com
14d8fdb295 Fix for Bug #17840 mysqldump should not dump tables in database cluster, skip cluster internal database 2006-04-24 15:39:49 +02:00
msvensson@neptunus.(none)
a51668c74c Bug#17208 SSL: client does not verify server certificate
- Add new function 'ssl_verify_server_cert' which is used if we are 
   connecting to the server with SSL. It will compare the hostname in 
   the server's cert against the hostname that we used when connecting 
   to the server. Will reject the connection if hostname does not match.
 - Add new option "OPT_SSL_VERIFY_SERVER_CERT" to be passed to mysql_options
   which will turn on checking of servers cert.
 - Add new argument "ssl-verify-server-cert" to all mysql* clients which 
   will activate the above option.
 - Generate a new server cert with 1024 bits that has "localhost" as the server name.
2006-04-18 17:58:27 +02:00
anozdrin@mysql.com
0e172496eb Merge mysql.com:/mnt/hda4/home/alik/MySQL/devel/5.0-tree
into  mysql.com:/mnt/hda4/home/alik/MySQL/devel/5.1-tree
2006-03-10 22:37:38 +03:00
anozdrin@mysql.com
41423cd05c Fix version of DEFINER-clause in mysqldump.
Now DEFINER-clause in stored routines is expected to appear
in 5.0.20 release, not in 5.0.19. as it was supposed before.
2006-03-10 22:23:04 +03:00
cmiller@calliope.local
34a74d65ba Merge calliope.local:/Users/cmiller/work/src/mysql-5.1-new
into  calliope.local:/Users/cmiller/work/src/mysql-5.1-new__cleanup_mysqldump
2006-03-09 22:23:35 -05:00
cmiller@calliope.local
d3c0dc0eed Added code to mysqldump to dump timed events when instructed to do so, with
the '-E' or '--events' flag.  (Closes Bug#16853 and Bug#17714.)


WARNING:

At present, these tests fail due to b*g number 18078.
2006-03-09 15:12:43 -05:00
anozdrin@mysql.com
c1ef46fcc7 Merge mysql.com:/home/alik/Documents/AllProgs/MySQL/devel/5.0-tree
into  mysql.com:/home/alik/Documents/AllProgs/MySQL/devel/5.1-merged
2006-03-09 20:41:21 +03:00
anozdrin@mysql.com
fbb5920399 Implementation of WL#2897: Complete definer support in the stored routines.
The idea is to add DEFINER-clause in CREATE PROCEDURE and CREATE FUNCTION
statements. Almost all support of definer in stored routines had been already
done before this patch.

NOTE: this patch changes behaviour of dumping stored routines in mysqldump.
Before this patch, mysqldump did not dump DEFINER-clause for stored routines
and this was documented behaviour. In order to get full information about stored
routines, one should have dumped mysql.proc table. This patch changes this
behaviour, so that DEFINER-clause is dumped.

Since DEFINER-clause is not supported in CREATE PROCEDURE | FUNCTION statements
before this patch, the clause is covered by additional version-specific comments.
2006-03-02 15:18:49 +03:00
msvensson@neptunus.(none)
f824345be6 Merge neptunus.(none):/home/msvensson/mysql/mysql-5.0
into  neptunus.(none):/home/msvensson/mysql/mysql-5.1
2006-02-23 16:11:47 +01:00
msvensson@neptunus.(none)
36a1d6392b Change snprintf to my_snprintf 2006-02-23 16:08:28 +01:00
msvensson@neptunus.(none)
167b625e62 Merge neptunus.(none):/home/msvensson/mysql/mysql-5.0
into  neptunus.(none):/home/msvensson/mysql/mysql-5.1
2006-02-23 14:35:57 +01:00
msvensson@neptunus.(none)
269ab365aa Aix52 build fix 2006-02-23 14:06:29 +01:00
msvensson@neptunus.(none)
d35ba92a24 Merge neptunus.(none):/home/msvensson/mysql/bug14871/my51-bug14871
into  neptunus.(none):/home/msvensson/mysql/mysql-5.1
2006-02-21 15:57:56 +01:00
msvensson@neptunus.(none)
a699a2ea1b Merge neptunus.(none):/home/msvensson/mysql/bug14871/my50-bug14871
into  neptunus.(none):/home/msvensson/mysql/mysql-5.0
2006-02-21 15:05:58 +01:00
msvensson@neptunus.(none)
f64effb570 Merge neptunus.(none):/home/msvensson/mysql/bug14871/my50-bug14871
into  neptunus.(none):/home/msvensson/mysql/bug14871/my51-bug14871
2006-02-21 15:03:15 +01:00
msvensson@neptunus.(none)
c293324eb0 Bug#14871 mysqldump: invalid view dump output
- Add comments with embeded veriosn info around the parts of the view syntax that are only supported by a certain version of MySQL Server
2006-02-21 13:21:17 +01:00
serg@serg.mylan
661371538b missing DBUG_RETURN 2006-02-16 12:31:33 +01:00
konstantin@mysql.com
e3663e7659 Merge bk-internal.mysql.com:/home/bk/mysql-5.1-new
into  mysql.com:/home/kostja/mysql/mysql-5.1-merge
2006-02-02 20:54:07 +03:00
konstantin@mysql.com
92b41ba92a Merge mysql.com:/home/kostja/mysql/tmp_merge
into  mysql.com:/home/kostja/mysql/mysql-5.1-merge
2006-02-02 16:57:34 +03:00
tomas@poseidon.ndb.mysql.com
92ffe8cf0d Bug #16753 DD: mysqldump does not support Cluster Disk Data backups 2006-02-02 10:56:04 +01:00
tomas@poseidon.ndb.mysql.com
8c024b9072 Bug #16753 DD: mysqldump does not support Cluster Disk Data backups 2006-02-02 00:52:58 +01:00
jimw@mysql.com
970aa54bd6 Fix mysqldump crash when encountering a VIEW (when used against a
5.0 or later server, obviously). (Bug #16389)
2006-02-01 12:28:39 -08:00
serg@serg.mylan
ae3d815b41 Merge bk-internal.mysql.com:/home/bk/mysql-5.0
into serg.mylan:/usr/home/serg/Abk/mysql-5.0
2006-01-16 18:09:04 +01:00
anozdrin@mysql.com
b1705ae5c4 Merge BUG#15110 from 5.0 into 5.1.
Merge mysql.com:/home/alik/MySQL/devel/5.0-bug15110
into  mysql.com:/home/alik/MySQL/devel/5.1-bug15110
2006-01-13 19:09:27 +03:00
anozdrin@mysql.com
b04b851ef9 Fix for BUG#15110: mysqldump --triggers: does not include DEFINER clause
There are two main idea of this fix:
  - introduce a common function for server and client to split user value
    (<user name>@<host name>) into user name and host name parts;
  - dump DEFINER clause in correct format in mysqldump.
2006-01-11 02:07:40 +03:00
serg@serg.mylan
14f94dc0ca many warnings (practically safe but annoying) corrected 2006-01-03 17:54:54 +01:00
jani@a193-229-222-105.elisa-laajakaista.fi
d88d8081da Merge a193-229-222-105.elisa-laajakaista.fi:/home/my/bk/mysql-4.0
into  a193-229-222-105.elisa-laajakaista.fi:/home/my/bk/mysql-4.1
2005-12-04 15:34:47 +02:00
jani@a193-229-222-105.elisa-laajakaista.fi
669a12fdb0 A set of Netware related patches. 2005-12-04 15:02:06 +02:00
jimw@mysql.com
01ac5172dd Merge mysql.com:/home/jimw/my/mysql-5.0-clean
into  mysql.com:/home/jimw/my/mysql-5.1-clean
2005-12-01 15:14:51 -08:00
jimw@mysql.com
beed6147ad Merge mysql.com:/home/jimw/my/mysql-4.1-13318
into  mysql.com:/home/jimw/my/mysql-5.0-clean
2005-12-01 12:21:29 -08:00
bar@mysql.com
23c4c3abc0 Merge mysql.com:/usr/home/bar/mysql-5.0
into  mysql.com:/usr/home/bar/mysql-5.1-new
2005-11-29 09:30:29 +04:00
brian@zim.(none)
22183f2342 Fixed typo where I did --replace-names intead of --replace.
Thanks Paul for pointing it out :)
2005-11-28 19:44:55 -08:00
jimw@mysql.com
5f7e5b46c6 Merge mysql.com:/home/jimw/my/mysql-4.1-5792
into  mysql.com:/home/jimw/my/mysql-5.0-clean
2005-11-28 10:52:52 -08:00
brian@zim.(none)
802f32c1dd Merge baker@bk-internal.mysql.com:/home/bk/mysql-5.1-new
into  zim.(none):/home/brian/mysql/mysql-5.1-new
2005-11-24 11:23:44 -08:00
brian@zim.(none)
33076b8782 Its funny, I am reading through the forums and someone asks "Can I please have a REPLACE INTO, instead an INSERT INTO?" and I remember how often I have used a sed script to modify MySQL dumps to have exactly that.
So, use --replace and instead of getting INSERT INTO you will INSTEAD get REPLACE INTO. Buyer beward, REPLACE is a MySQL SQL, so you will not end up with a dump that can be used for other databases.

Though I hear you could just use a sed line to modify it back :)
2005-11-24 09:56:40 -08:00
jimw@mysql.com
000d89b5e0 Fix values printed by mysqldump for empty blob fields when
--hex-blob is used. (Bug #13318)
2005-11-23 17:31:44 -08:00
joerg@mysql.com
84bc725fb9 Merge jbruehe@bk-internal.mysql.com:/home/bk/mysql-5.0
into mysql.com:/M50/mysql-5.0
2005-11-21 18:31:36 +01:00
aivanov@mysql.com
9a7efe36c6 Fixed BUG #14554: mysqldump does not separate "ROW" and trigger
statement for tables created in the IGNORE_SPACE sql mode.
2005-11-21 13:36:48 +03:00
jamppa@suse9-x86.mysql.com
a50cc250ff Netware specific changes for 5.0.16a 2005-11-18 18:25:46 +01:00
paul@frost.snake.net
19544bd01c Merge paul@bk-internal.mysql.com:/home/bk/mysql-5.0
into  frost.snake.net:/Users/paul/bk/mysql-5.0
2005-10-28 14:26:22 -05:00
monty@mysql.com
a9b1ff4095 Add DROP TABLE before trying to create view (in mysqldump)
Cleaned up xxxx_gis.test's and made gis_generic.inc independent of ndb
(Note that archive_gis.test fails, but this is independent of this patch)
2005-10-27 22:45:18 +03:00
paul@frost.snake.net
ea8ab2a114 Merge paul@bk-internal.mysql.com:/home/bk/mysql-5.0
into  frost.snake.net:/Users/paul/bk/mysql-5.0
2005-10-25 12:50:03 -05:00
pgalbraith@mysql.com
feca138e46 This cset fixes BUG# 12838, 14061, 12129
mysqldump.result:
  BUG# 12838
      New test results for mysqldump -x on a DB with views
mysqldump.test:
  sqldump.test:
      BUG# 12838
      New test to run mysqldump -x on a DB with views
mysqldump.c:
  BUG# 12838
      Removed/Changed code which created tables to be put into the dump
      (For loading views of views) by creating temp tables and then using
      the CREATE TABLE information in those temp tables. The problem with this
      is that when mysqldump -x is called, it locks all tables, so the
      temp tables could not be created, causing the mysqldump to exit with
      failure. The code was changed to use SHOW FIELDS to get the column
      names and type to build CREATE TABLE text used to create these tables
      that views need in the dump.
2005-10-25 19:04:31 +02:00
paul@frost.snake.net
5d2c1d4cc2 mysqldump.c:
Slight change to help message.
2005-10-19 14:40:10 -05:00
patg@krsna.patg.net
f1bd9c0d0a Changeset:
Changed option text in mysqldump.c
mysqldump.c:
  Changed text to read "+00:00" as opposed to "UTC" (per what the code does)
2005-10-18 18:51:07 -07:00
patg@krsna.patg.net
1423db9f0c BUG# 13052 Changed text in options to TIMESTAMP 2005-10-17 12:30:01 -07:00
patg@krsna.patg.net
d86f40650f BUG# 13146
Re-application of patch to clean 5.0 tree. Fixed issue with ANSI quotes 
when dumping triggers
2005-10-13 13:42:56 -07:00
jimw@mysql.com
b6dcc55969 Fix being able to set default TCP port for command-line utilities
by using MYSQL_TCP_PORT variable. (Bug #5792)
2005-10-13 12:28:43 -07:00
patg@krsna.patg.net
a46dd41255 BUG# 13052
Clean application of patch - 
- Added --tz-utc to fix issue of dumping timestamp values between 
servers with different global time zone settings, particularly 
with regard to the day of DST changeover, which without this fix,
 would dump duplicate timestamp values.
2005-10-12 22:44:42 -07:00
monty@mysql.com
f5fdf3e87a Reviewing new pushed code
- CHAR() now returns binary string as default
- CHAR(X*65536+Y*256+Z) is now equal to CHAR(X,Y,Z) independent of the character set for CHAR()
- Test for both ETIMEDOUT and ETIME from pthread_cond_timedwait()
  (Some old systems returns ETIME and it's safer to test for both values
   than to try to write a wrapper for each old system)
- Fixed new introduced bug in NOT BETWEEN X and X
- Ensure we call commit_by_xid or rollback_by_xid for all engines, even if one engine has failed
- Use octet2hex() for all conversion of string to hex
- Simplify and optimize code
2005-10-12 00:58:22 +03:00
monty@mysql.com
17d7ba931d Merge bk-internal.mysql.com:/home/bk/mysql-5.0
into  mysql.com:/home/my/mysql-5.0
2005-10-08 03:37:23 +03:00