Page 1 of 1

Mysql stored procedure using TZStoredProc

Posted: 27.09.2007, 09:22
by matejka
Hi,
i'm using Zeos DBO 6.6.0, MySQL 5.0.41 and I need to retrieve result set from stored procedure. I've used TZStoredProc with params like this:

StoredProc1:=TZStoredProc.Create(nil);
StoredProc1.Connection:=Connection1;
StoredProc1.Params.CreateParam(ftInteger, 'param1', ftInput);
... other params added
StoredProc1.Open; // exception here

But exception of "Unsupported operation" occurs when calling Open (same error when calling Exec). I use only IN params in this procedure.

Is there anything wrong in my code?

thanks

Jiri Matejka

Posted: 27.09.2007, 12:10
by mdaems
No... Nothing's wrong with your code. TZStoredProc is not supported for mysql, however. You should just use a TZQuery component (or TZReadOnlyQuery) ans use 'Call proc(param)' as the SQL statement.

There are plenty of examples on the forum already.

Mark

Posted: 27.09.2007, 12:46
by matejka
Thanks for help, I'll try it.

Jiri Matejka