Results 1 to 1 of 1
  1. #1
    Join Date
    Apr 2004
    Posts
    5

    Unanswered: no results from Sybase::DBLib->results

    Hello:

    I run the following query from isql:
    'select pr.nr, sa.value, sa.attributenr from products pr, string_attribute sa where pr.nr=sa.productnr and pr.shopproduct=1 and (sa.attributenr="1012" or sa.attributenr="1013" or sa.attributenr="1069") and NOT EXISTS (select sp.sub from sub_products sp where sp.sub=pr.nr)'
    and it returns several thousand results.

    However when I put it in the Sybase::DBLib command buffer with
    my $query = "above query";
    my $dbh = Sybase::DBLib->new('un', 'pw', 'server');
    $dbh->dbcmd("$query");
    $dbh->dbsqlexec;
    $dbh->dbresults;
    while (@results = $dbh->dbnextrow) {
    more statements;
    }

    there are no iterations of the while loop.

    Please help.

    Adam
    Last edited by adamgotch; 06-17-04 at 17:28.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •