ronniec has asked for the wisdom of the Perl Monks concerning the following question:
The $table variable points to a table called USER$ - where our user names live & $column is set to COLUMN_NAME. This script runs but no rows are returned. I take it that I'm doing something particularily daft but can't see what it is can someone give me some pointers please?print "\n\t\t***** S T A R T S *****\n" ; $dbh = DBI->connect("dbi:Oracle:$db","$uname","$password", { PrintError => 0, RaiseError => 0 } ) or die "\n\tCan't connect to $db :: $DBI::errstr\n" ; $sth = $dbh->column_info(undef,undef,"$table","$column") or die "\n\tD +idnae work min :: $!\n" ; $sth->execute or die "\n\tCan't execute DBI command :: $DBI::errstr\n" + ; #------------------------------------------# # Retrieve the returned rows of data # #------------------------------------------# while ( @row = $sth->fetchrow_array() ) { $detail = $row[0] ; $row_count ++ ; print "\n\tValue\t$detail\n" ; } print "\n\tThere were $row_count rows returned\n" ;
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Finding column info from Oracle tables
by swampyankee (Parson) on Jul 03, 2007 at 15:10 UTC | |
by ronniec (Sexton) on Jul 05, 2007 at 10:16 UTC | |
by lbjay (Novice) on Jul 19, 2007 at 16:18 UTC | |
|
Re: Finding column info from Oracle tables
by Mr. Muskrat (Canon) on Jul 03, 2007 at 15:27 UTC |