Help for this page

Select Code to Download


  1. or download this
    sub IS4_SQL_execute {
    #accept the SQL, then a list containing the bind values
    ...
    # I count on the calling sub finishing the statement
    # and disconnecting
    }
    
  2. or download this
    my $sql = 'SELECT count(*) FROM products WHERE nr = ?';
    my ($dbh,$sth) = IS4_SQL_execute($sql,$nr);
    ...
    }
    $sth->finish;
    $dbh->disconnect;