Hello,

      I'm trying to fetch data from 2 stored procedures one after
      another and i'm getting weird error message when it start to
      fetch from second one. Here is a code snippet
      ----
      my $sth1 = $dbh->prepare("call sp_Get_Buildings()");
      $sth1->execute();

      my $sth2 = $dbh->prepare("call sp_Get_Streets()");
      $sth2->execute();

      print "1st sth" while($sth1->fetch);
      print "2nd sth" while($sth2->fetch);
      ----
      
      On last line it writes
      ---
      DBD::DB2::st fetch failed: [IBM][CLI Driver] CLI0125E  Function se
      quence error. SQLSTATE=HY010 at 1.pl line 12.
      ---

      I already found several solutions for this - place each out after
      corresponding while($sth->fetch), but it isn't suit for me, cos in
      real project i have to at first prepare each $sth and only then do
      smth with them. Another solution is to replace call to stored
      procedure by SQL statement itself, but i think it's not good...

      So, here are a couple of questions:
          1. What does that error message mean ?
          2. How i can get rid of it ?

      Thanks in advance.
      
-- 
Best regards,
 Alex                          mailto:[EMAIL PROTECTED]



_________________________________________________________
Do You Yahoo!?
Get your free @yahoo.com address at http://mail.yahoo.com

Reply via email to