2 messages in com.mysql.lists.mysqlproblems with show script
FromSent OnAttachments
Ivan Baxter05 Feb 2000 14:13 
Thimble Smith07 Feb 2000 21:14 
Subject:problems with show script
From:Ivan Baxter (ibax@scripps.edu)
Date:02/05/2000 02:13:53 PM
List:com.mysql.lists.mysql

I am having problems getting the output from a show tables command with a perl script that I am using.

use DBI;

open (STDERR, ">>errorfromtestline")|| die "couldn't open standard error"; $han=con_db(); print "connected to DB\n"; $sql="show columns from 113results"; $send=$han->prepare($sql); $send->execute; $rows=$send->rows; print "$rows\n"; my @names; $i=1; while ($i <= $rows){ $names[$i][]=$send->fetchrow_array; print "$names[$i][]"; $i++; } $out="$names[1]\t"; $j=2; while($j<=$rows){ $out.="$names[$j]\t"; $j++; } print "$out\n";

When I put "select * from 113results" as the query, I get the output I am expecting. But when I leave it as "show columns from 113results, the row command gives the correct number, but the script doesn't seem to return any of the output. AM I doing something wrong??

thanks

Ivan