in reply to Re: dbi retieve single col value
in thread dbi retieve single col value

Hi thanks I tried this way,it still does not enter the while loop to print the statement:print "Entering taxID_format with $t\n";
LOOP:foreach $ref(@ref) { print "in foreach loop with $ref\n"; $count=0; $command1 = qq{select distinct tax_id from gene2acc where genomic_ac +_ver= '$ref'; }; $sth1=$dbh->prepare($command1); $sth1->execute() or die $sth1->errstr; my($tax_id); $sth1->bind_columns(undef,\$tax_id ); while($sth1->fetch()) { $t=$tax_id; print "Entering taxID_format with $t\n"; #&taxID_format($t); }
please help me