no multiple record returns 
Author Message
 no multiple record returns

I have been using the Win32::ODBC module with some success to return stuff
from a SQL Server db, however the result set is limited to only the first
record, though I expect multiples returned.  I have used the de{*filter*} to
step into the module, but it appears to be working correctly, so I am sure
that there is some error in my code.

Any ideas?

Below is my code:

 $ThisURL = "IBM";
 use Win32::ODBC;
 $db = new Win32::ODBC("DSN=KScriptDB;UID=sa;PWD=;") or die $!;
 $sql =  "EXECUTE usp_BrowseCacheTest1 '%$ThisURL%' ";

 while ($db->FetchRow()) {
  ($URLKey, $URL, $Cache, $TimeOut, $LastUpdate, $LastUpdateUTC,
$CacheStatus) = $db->Data("URLKey", "URL", "Cache", "TimeOut", "LastUpdate",
"LastUpdateUTC", "CacheStatus");

  print "$URLKey\n";
  print "$LastUpdate\n";
  print "$TimeOut\n";
  print "$CacheStatus\n";


 return $nCounter;


Sun, 22 Dec 2002 03:00:00 GMT  
 [ 1 post ] 

 Relevant Pages 

1. reading multiple line records efficiently

2. Multiple records with the same key

3. Ignore multiple input record seperators

4. with multiple records in a file

5. Multiple line records

6. recgrep - search for an expression, return a record

7. DBI limits sometimes nr of records returned?

8. SDBM_File - %HASH not returning all records ?

9. Returning Multiple Values in Perl

10. Returning multiple arrays in a function?

11. how to return multiple values in perl?

12. Multiple Return Streams from CGI process


Powered by phpBB® Forum Software