it's a really good habit to get into. For instance, in your script, what is $Sql_test?use strict;
The documentation I have suggests that you can connect with only the DSN name. (this is the part where the cross the "t's and dot the i's" comes in, but) Make sure that you have the proper driver installed for your DSN type, and try embedding the username and password in the DSN (most of the drivers I've seen will allow you to actually do that).$db = new Win32::ODBC("DSN=clamon.world;UID=scott;PWD=tiger");
This is of course an alternate suggestion to try if you're banging your head against this horribly. Note, I haven't tested this, so treat it as if you would any psuedocode. Good luck with it.use strict; use Win32::OLE; my $db = CreateObject OLE "ADODB.Connection"; $db or die "Whoa partner!"; $db->Open("DSN=clamon.world;UID=scott;PWD=tiger"); my $rs = $db->Execute("SELECT * FROM EMP where EMPNO = 7900"); print ($_)->{Description}."<br>\n" foreach(keys %{$db->Errors()}) unle +ss($rs); while(!$rs->EOF){ #see the ADO documention for getting out the data you want $rs->MoveNext(); }
In reply to Re: Problem getting data from win32::ODBC connection to oracle
by JayBonci
in thread Problem getting data from win32::ODBC connection to oracle
by RuneK
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |