Bug #14165 libmysqld: Routine body is too long
Submitted: 20 Oct 2005 6:58 Modified: 5 Feb 2006 20:41
Reporter: Peter Schäfer Email Updates:
Status: No Feedback Impact on me:
None 
Category:MySQL Server: Embedded Library ( libmysqld ) Severity:S2 (Serious)
Version:5.0.16, nightly build 20051017 OS:Microsoft Windows (Windows 2003)
Assigned to: Assigned Account CPU Architecture:Any

[20 Oct 2005 6:58] Peter Schäfer
Description:
when creating a new function, libmysqld responds with the following error:

 1437: Routine body for 'simplefunc' is too long (42000)

it used to work with 5.0.13-rc, but it's broken in 5.0.16-nightly-20051017

How to repeat:
CREATE FUNCTION simplepi() RETURNS DOUBLE RETURN 3.141

returns error code 1437: Routine body for 'simplepi' is too long (42000)
[20 Oct 2005 7:13] Valeriy Kravchuk
Thank you for a problem report. If you had a complete test caser (lloks like you have), please, send it.

I've tried to create such a function in mysql client, and it works both in 5.0.13-rc on Windows and in newer 5.0.15-BK build (ChangeSet@1.2007.4.1, 2005-10-18 18:51:07-07:00, patg@krsna.patg.net) on Linux:

mysql> CREATE FUNCTION simplepi() RETURNS DOUBLE RETURN 3.141;
Query OK, 0 rows affected (0,09 sec)

mysql> select simplepi();
+------------+
| simplepi() |
+------------+
|      3.141 |
+------------+
1 row in set (0,01 sec)

mysql> select version();
+-----------+
| version() |
+-----------+
| 5.0.15    |
+-----------+
1 row in set (0,00 sec)
[20 Oct 2005 8:35] Peter Schäfer
Test Case with embedded library

Attachment: TestCase14165.cpp (application/octet-stream, text), 1.28 KiB.

[20 Oct 2005 8:37] Peter Schäfer
I'm using the EMBEDDED LIBRARY, version 5.0.16-nightly-20051017
(sorry, if I forgot to mention)

see the attached file for a test case.
It produces the following output:
--------------------------
5.0.13-rc-embedded
0:  (00000)
--------------------------
5.0.16-nightly-20051017-pro-embedded
1437: Routine body for 'simplepi' is too long (42000)
--------------------------
[20 Oct 2005 8:44] Peter Schäfer
one more question: why can't I see this bug under "View your bugs" ?
[5 Jan 2006 20:41] Hartmut Holzgraefe
works fine for me with current 5.0 bitkeeper source, seems to have been fixed since.
or does it still happen for you with latest sources (i've been testing on linux, not windows ...)?
[6 Feb 2006 0:00] Bugs System
No feedback was provided for this bug for over a month, so it is
being suspended automatically. If you are able to provide the
information that was originally requested, please do so and change
the status of the bug back to "Open".