Situation: two machines. Same versions of DBI and DBD::mysql.
Running the following sub:
use DBI; my $dbh; open_db_conn(); my @active_homes = get_active_homes(); $dbh->disconnect(); sub open_db_conn { my $dbd = "mysql"; my $host = "host_name"; my $db_name = "db_name"; my $user = "login"; my $password = "pass"; my $dsn = "DBI:$dbd:$db_name:$host"; eval { $dbh = DBI->connect( $dsn, $user, $password, { RaiseError => 1, AutoCommit => 0 } ); }; print "Could not open database connection: $@" if $@; } # &open_db_conn # Get active homes. # sub get_active_homes { my $sth = $dbh->prepare( qq{ call myProc() } ); $sth->execute(); print "Trouble with database connection: $@" if $@; } # &get_active_homes

Code runs fine on machine #1.
Running on machine #2 returns the following:
DBD::mysql::st execute failed: PROCEDURE db_name.myProc can't return a result set in the given context at ./test0.pl line 32.
DBD::mysql::st execute failed: PROCEDURE db_name.myProc can't return a result set in the given context at ./test0.pl line 32.


Both systems report the following from CPAN:
cpan[1]> i DBD::mysql CPAN: Storable loaded ok Going to read /u/user/.cpan/Metadata Database was generated on Wed, 13 Jun 2007 03:07:59 GMT Strange distribution name [DBD::mysql] Bundle Bundle::DBD::mysql (CAPTTOFU/DBD-mysql-4.005.tar.gz) Module DBD::mysql (CAPTTOFU/DBD-mysql-4.005.tar.gz) 2 items found cpan[2]> i DBI Strange distribution name [DBI] Bundle Bundle::DBI (TIMB/DBI-1.56.tar.gz) Module DBI (TIMB/DBI-1.56.tar.gz) 2 items found

What other modules do I need to synch?
What other step(s) did I miss?

In reply to problem calling MySQL stored proc by ethrbunny

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.