pem@mysql.comhem.se
c0ae841258
Fixed BUG#2653: Undeclared variables not detected in stored procedures.
...
We now get an run-time error instead of a crash (although a slightly misleading
error message, but it's an improvement).
2004-07-21 14:53:09 +02:00
monty@mysql.com
5b3c418b48
After merge fixes
...
Note: The following tests fails
- fulltext (Sergei has promised to fix)
- rpl_charset (Guilhem should fix)
- rpl_timezone (Dimitray has promised to fix)
Sanja needs to check out the calling of close_thread_tables() in sp_head.cc
2004-07-15 04:19:07 +03:00
paul@kite-hub.kitebird.com
23fa7987e0
variables.result, sp-error.result:
...
fix up test result.
2004-06-16 00:46:26 -05:00
pem@mysql.comhem.se
ecd424ac58
Fixed BUG#3339: Stored procedures in nonexistent schemas are uncallable.
...
Also added some related security tests and corrected related error messages.
2004-06-15 15:42:28 +02:00
pem@mysql.comhem.se
a3082cd3c9
Added test case for SELECT INTO with too many rows.
2004-06-09 18:50:03 +02:00
pem@mysql.comhem.se
ec92106535
Post-merge fixes.
...
Note: One sp.test still fails (prime), and rpl_server_id2.test fails (will be fixed by guilhem ASAP).
2004-05-14 16:00:57 +02:00
pem@mysql.comhem.se
d42b145817
Post-merge fixes, some quite complex. client/mysqlbinlog.cc and sql/log_event.cc
...
merged manually by guilhem.
2004-04-28 12:08:54 +02:00
pem@mysql.comhem.se
95dcdde134
Fixed BUG#3287: Stored procedure handler scope outside of begin/end.
...
Backpatching overwrote already backpatched instructions, which made it
skip the hpop instruction; possibly not only a problem for handlers,
but this is one known case when it happened.
2004-04-05 17:01:19 +02:00
pem@mysql.comhem.se
329013f99e
Fixed BUG#3287: Stored Procedure Case Statement Not SQL:2003 Compliant.
2004-03-29 12:29:06 +02:00
pem@mysql.comhem.se
52c820fbc5
Enforce standard declaration order in SPs.
...
Added new test cases for this, and adjusted old tests accordingly,
and new error codes and messages.
Fixed bugs in some tests (bug2673 and use test).
Added debug printing of instructions in SPs.
2004-03-29 11:16:45 +02:00
pem@mysql.comhem.se
6c6bbba007
WL#1366: Use the schema (db) associated with an SP.
...
Phase 2: Make SPs belong to a DB, and use qualified names.
As a side effect, using USE in an SP is no longer allowed.
(It just doesn't work otherwise.)
2004-03-11 17:18:59 +01:00
pem@mysql.comhem.se
f9e73c7716
Post-merge fixes.
2004-02-11 18:21:55 +01:00
pem@mysql.comhem.se
370a43a32a
Fixed BUG#2329: Crash if insert with variable name in stored procedure.
...
Found a few more places in the parser (insert, replace and update) where
local stored procedure variables should not be recognized.
2004-01-14 12:47:03 +01:00
pem@mysql.comhem.se
cfd97c022e
Fix BUG#2259: Crash after fetch from not-open cursor in stored procedure
...
Initialize and test properly when cleaning up, to avoid crash in some error cases.
2004-01-08 10:37:31 +01:00
pem@mysql.comhem.se
4975595660
Fix BUG#2272: Crash if update with variable name in stored procedure.
...
Parse column names (and not variables) only in UPDATE ... SET ...
2004-01-08 09:27:29 +01:00
pem@mysql.comhem.se
bb51272bd1
Post-merge fixes.
...
Multiple result sets from stored procedures now works with the
mysql and mysqltest clients.
2003-12-16 18:09:22 +01:00
pem@mysql.comhem.se
07541b6abf
WL#1365: Implement definer's rights execution of stored procedures.
...
(Also put the hostpart back in the definer column.)
2003-12-13 16:40:52 +01:00
pem@mysql.comhem.se
cbdc0b4c3a
Post-merge fixes.
2003-12-05 14:45:48 +01:00
pem@mysql.comhem.se
a5780a4815
Fixed BUG#336: Subselects with tables does not work as values for local SP variables
...
and BUG#1654: Stored Procedure Crash if contains subquery and set function
Disallowed subselects in RETURN (for FUNCTIONs) and SET of local variables.
The latter should work, but turned out to be difficult to fix, so we just
disallow it for the time being.
2003-12-04 15:17:55 +01:00
pem@mysql.comhem.se
3ed561d3cf
Post-merge fixes.
2003-12-01 18:24:09 +01:00
pem@mysql.comhem.se
d8bf426b80
Fixed BUG#1965: Opening a cursor hangs client when malformed select fails
...
and BUG#1966: "select 1 into a" on top-level hangs client
2003-11-27 16:48:21 +01:00
pem@mysql.comhem.se
47f9c2946f
Changed "query" into "statement", and corrected SQL state code (04000->0A000).
2003-11-24 18:24:14 +01:00
pem@mysql.comhem.se
d9b8a35eeb
Translated 5.0 error codes into sql states.
2003-11-21 18:23:05 +01:00
pem@mysql.comhem.se
96f1252899
Bugfixes in SHOW CREATE PROCEDURE/FUNCTION and SHOW PROCEDURE/FUNCTION STATUS;
...
- dropped routines should not show up in status
- error handling for non-existing routines
+ some cleanup.
2003-11-20 15:07:22 +01:00
pem@mysql.comhem.se
5b355ea6f5
Post-merge fixes.
2003-11-19 16:59:35 +01:00
pem@mysql.comhem.se
c4871b240d
Fixed BUG#1862 (flush table in SPs didn't work).
...
Fixed various bugs: setting local variables to NULL, SELECT INTO var now actually
might work, SELECT INTO with not row now gives a "no data" warning (instead of
the "empty query" error), etc.
Updated test cases accordingly.
2003-11-19 11:26:18 +01:00
gluh@gluh.mysql.r18.ru
ee4ed0c969
WL#1241: SHOW PROCEDURE/FUNCTION
...
WL#1263: Support for the attributes COMMENT and SUID
in CREATE/ALTER PROCEDURE/FUNCTION
2003-11-17 21:21:36 +04:00
pem@mysql.comhem.se
81c4cca686
Changed single generic error code/message into different ones for duplicate things.
...
(For multi-lingual support.)
Also fixed memory leak when aborting parsing for a duplicate cursor.
2003-11-14 13:46:50 +01:00
pem@mysql.comhem.se
c38bb3d79d
Various bug fixes:
...
- Duplicate parameters/variables, conditions and cursors (not allowed).
- ITERATE in labelled BEGIN-END (not allowed).
- Missing SQLSTATE [VALUE] keywords in CONDITION/HANDLER declaration (added).
- Empty BEGIN-END (now allowed).
- End label (now optional).
2003-11-13 19:34:56 +01:00
pem@mysql.comhem.se
692609537d
Post-merge fixes.
2003-10-23 16:06:51 +02:00
pem@mysql.telia.com
689bb84f72
WL#962: Added simple, read-only, non-scrolling, asensitive cursors in SPs, using the
...
(updated) Protocol_cursor class.
Also did some bug fixes.
2003-10-10 16:57:21 +02:00
pem@mysql.telia.com
e8634f80bd
Check that a FUNCTION contains RETURN and that we actually get a return value.
2003-10-03 17:38:12 +02:00
pem@mysql.telia.com
6e55a3428a
Post-merge fixes.
2003-09-24 15:26:20 +02:00
pem@mysql.telia.com
04f0570fe8
Implemented SP CONDITIONs and HANDLERs, with the extension of handling
...
MySQL error codes as well.
(No UNDO HANDLERs yet, and no SIGNAL or RESIGNAL.)
WL#850
2003-09-16 14:26:08 +02:00
pem@mysql.telia.com
08e5a7e135
Post-merge fixes.
2003-08-26 17:41:40 +02:00
pem@mysql.telia.com
a8a29a39d2
Merging 4.1 into 5.0 (second pass; post-merge fixes).
...
One test in subselect.test still wrong.
Had to reconstruct all errmsg.txt files completely, since auto-merge made
a mess of the lot. :-(
2003-07-09 17:07:12 +02:00
pem@mysql.com
541c94fcf1
Fixed bug #643 , which caused intermittent crashes in net_printf() with repeated
...
syntax errors in stored procedures.
2003-06-12 15:31:20 +02:00
pem@mysql.com
a4e065920b
Made multiple queries (SELECT without INTO) work in SPs.
...
This included bug fixes in the 4.1 protocol (actually send and receive the
server_status flags).
2003-04-23 09:22:54 +02:00
pem@mysql.com
7b5df9edec
Check the number of args to SPs.
...
Fixes bug #280 .
2003-04-17 13:20:02 +02:00
pem@mysql.com
0e006f5650
Post-merge fixes.
2003-04-17 00:18:29 +02:00
pem@mysql.com
462430ba55
Post merge fixes.
2003-04-04 15:47:43 +02:00
pem@mysql.com
2578564725
Added IF EXISTS to DROP PROCEDURE|FUNCTION.
...
Changed another unecessary use of Item_string into LEX_STRING (in sp_pcontext).
2003-03-26 12:29:58 +01:00
pem@mysql.com
12f771d9e7
Improved error handling regarding SPs (with info like names etc in the output).
...
Disabled queries in FUNCTIONs.
2003-03-05 19:45:17 +01:00