McMahon, Chris wrote:
Hello... This script: *******************************
use warnings; use Win32:ODBC; my $db = new Win32::ODBC("TheDB");


$db->Sql("SELECT * FROM dbo.foo");
$db->FetchRow();
my @values = $db->Data;
print @values; *************************************
Yields two "Use of uninitialized value in print..." error messages before it prints @values.


If anyone could explain why (and maybe how to get rid of them), I'd appreciate it... -Chris



Sorry to reply to my own post, but it seems that NULL values in the
tables themselves cause the "uninitialized value" warnings. This seems like strange behavior-- if anyone can suggest a way to
shut them down without losing -w, please make a suggestion... -Chris (again)



That will depend on what FetchRow and Data are doing... maybe using DBI instead of Win32::ODBC?


perldoc perllexwarn

For more on silencing unwanted warnings...

You aren't using 'strict' and I assume you are doing 'use Win32::ODBC' instead of with 1 colon, what does your real code look like...

http://danconia.org

--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
<http://learn.perl.org/> <http://learn.perl.org/first-response>




Reply via email to