Bug#33812: mysql client incorrectly parsing DELIMITER
Remove unnecessary and incorrect code that tried
to pull delimiter commands out of the middle of
statements.
as a commentary
mysql client has been modified to interpret EOL after
standalone -- commentary strings like whitespace
character (according to
http://dev.mysql.com/doc/refman/5.0/en/ansi-diff-comments.html)
mysql-test/t/mysql_delimiter.sql:
Added test case for bug #36244.
- Use more appropriate test case.
mysql-test/r/mysql.result:
Bug#19799 delimiter command not working correctly when sourcing a sql file
- Alt. Result.
mysql-test/t/mysql_delimiter.sql:
Bug#19799 delimiter command not working correctly when sourcing a sql file
- Alt. Test
- Client side readline functions unconditionally search for Unix '\n' line
endings. In this case, the delimiter statement was set to '//\r' instead
of the intended '//'. When removing the '\n' check for and remove
preceeding '\r' character as well.
client/readline.cc:
Bug#19799 delimiter command not working correctly when sourcing a sql file
- When removing the '\n' character, check for and remove preceeding '\r'
character as well.
mysql-test/r/mysql.result:
Bug#19799 delimiter command not working correctly when sourcing a sql file
- Added Results.
mysql-test/t/mysql_delimiter.sql:
Bug#19799 delimiter command not working correctly when sourcing a sql file
- Added Tests.
mysql-test/t/mysql_delimiter_19799.sql:
Bug#19799 delimiter command not working correctly when sourcing a sql file
- File containing delimiter statement followed by '\r\n' line ending.
in sourced file properly. (Bug #11523)
client/mysql.cc:
Rename read_lines() to read_and_execute() and change interface so it
is clear when we are reading and processing lines interactively versus
in batch mode or from a file being sourced.
mysql-test/r/mysql.result:
Add results
mysql-test/t/mysql_delimiter.sql:
Add new test
mysql-test/t/mysql_delimiter_source.sql:
New BitKeeper file ``mysql-test/t/mysql_delimiter_source.sql''
- Added testcases to test delimiters in 5.0
- In 5.0 it's allowed to have a up to 16 byte string as delimiter, everything after the delimiter token will be treated as the delimiter. It's even allowed to set delimiter to 'delimiter', ':;' or'MySQL'