in reply to Re^3: NET:MySQL database connection error -- (Using password: NO) at MySQL_queryDB.pl
in thread NET:MySQL database connection error -- (Using password: NO) at MySQL_queryDB.pl

got it working with DBI.... the only thing is if I want to pull back a table from the Database ... it is returned in the form of DBI::st=HASH(0xa0dc0c0) ... Is there anyway of pulling back the Table contents in a more readable format??
  • Comment on Re^4: NET:MySQL database connection error -- (Using password: NO) at MySQL_queryDB.pl

Replies are listed 'Best First'.
Re^5: NET:MySQL database connection error -- (Using password: NO) at MySQL_queryDB.pl
by zwon (Abbot) on Sep 24, 2009 at 17:02 UTC

    You can get result as array using one of the following functions:

    $ary_ref = $dbh->selectall_arrayref($statement); $hash_ref = $dbh->selectall_hashref($statement, $key_field);
    Consider to read DBI documentation. Also if you provide us with your code then asking question it would be simpler to give you useful answer.