MySQL Forums :: Stored Procedures :: Calling 'Select' procedure from Perl

Advanced Search

Calling 'Select' procedure from Perl
Posted by: sainandoor ()
Date: May 12, 2005 03:16PM

Hi Folks,
I am trying to call a "select" stored procedure from perl. I am not quite sure how to do it. Here is the stored procedure:

CREATE PROCEDURE spTest() begin select x AS X from tblTest;

It works fine when called from within MySQL.

mysql> call spTest():
| X |
| 24 |
| 3 |

I have the following code in perl:

my $spt = $db->prepare("Call spTest()");
print "X = $id";

I get an error that says I need to use "select into". How do I call this procedure from perl?

Options: ReplyQuote

Subject Views Written By Posted
Calling 'Select' procedure from Perl 2853 sainandoor 05/12/2005 03:16PM
Re: Calling 'Select' procedure from Perl 1901 Andrew Gilfrin 05/13/2005 02:09AM

Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.