Re: odbc problems in 4.2
| From: | Dan Kalowsky | Date: | Wed, 24 Apr 2002 22:05:46 +0000 |
| Subject: | Re: odbc problems in 4.2 | ||
| References: | 1 | Groups: | php.dev |
| Request: | Send a blank email to php-dev+get-83284@lists.php.net to get a copy of this message | ||
Hi Ryan,
Okay did a little looking over the odbc_fetch_row code, and it should
reset the result->fetched to whatever the second argument (if one is
provided) is. This variable is how the ODBC result system handles where
it currently is in the cache. Now the catch is that odbc_result checks
this value, and if it's set to 0 re-fetches the results.
So in otherwords the code sample you sent should work, provided that the
$rs is a valid result. I'm having some local DB access/ODBC issues so I
cannot test it right at the moment. I'm working on fixing that.
On Wed, 24 Apr 2002, Ryan Jameson (USA) wrote:
> If this is easy for anyone could someone verify that:
>
> odbc_fetch_row($rs,0);
>
> ...does not reset the result set in version 4.2? From what I can tell
>it doesn't work at all. I want to be certain that we cannot upgrade to
>4.2. If someone has another way to reset an ODBC result set I'd love to
>hear about it. It's done in a central core function, but is necessary in
>a plethora of scripts. The result set comes from the MS SQL Server driver
>(shhh... I tried to get them to use MySQL ... they are scared of free
>stuff. I'm just glad they let me use PHP). Thanks!
>
> <>< Ryan
>
>
>---------------------------------------------------------------<
Dan Kalowsky "The record shows, I took the blows.
http://www.deadmime.org/~dank And did it my way."
dank@nospam-deadmime.org - "My Way", Frank Sinatra
kalowsky@nospam-php.net