At 11:34 AM -0800 12/1/06, Chris White wrote:
On Friday 01 December 2006 11:22, Ed Reed wrote:
I have a problem/question I'd like to find someone else to verify/answer
for me.
I'm using MySQL 5.1.09 running on Netware. I've created a stored
procedure that has one parameter,
Create Procedure MyTest(strVal VarChar)
Begin
Select Field1, Field2, Field3 From MyTable
Where Field3=strVal;
End
varchar is meant to be variable, so it MUST have a length supplied. If you
want the same flexibility without specifying a specific length, use TEXT
instead.
Hmm ... I don't know. CHAR is equivalent to CHAR(1), but for VARCHAR
the length is not optional. For example, if you try to create a table
using a length-less VARCHAR, this happens:
mysql> create table t (c varchar);
ERROR 1064 (42000): You have an error in your SQL syntax; check the
manual that corresponds to your MySQL server version for the right
syntax to use near ')' at line 1
If you are able to create the procedure when no VARCHAR length is given,
I think that might be considered a bug. And it's certainly a problem
that you get "proc table is missing, corrupt, or contains bad data."
when attempting to invoke the procedure.
Ed, could you file a bug report about this issue at bugs.mysql.com?
That way, one of the developers can figure out what's going on and
resolve the issue.
Thanks.
--
Paul DuBois, MySQL Documentation Team
Madison, Wisconsin, USA
MySQL AB, www.mysql.com
--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe: http://lists.mysql.com/[EMAIL PROTECTED]