Jiri Cincura wrote: > On 2/26/08, Aitor Gómez González <[EMAIL PROTECTED]> wrote: >> Is there any reason to return an incorrect result instead of raising a >> NotSupportedException? > > I have not designed this. But according to ADO.NET abstract classes > and "expected" way of using this, I think, is this implemented as it > is. > > Maybe throwing exception is better from architecture POV, but change > this now will create huge breaking-change, and this is probably > impossible.
Instead of just returning true, couldn't you just attempt to fetch the first row? If there's no row, you can return false. If there's a row, you'll fetch it (and you'll have to cache it so the first call to MoveNext() works) and return true. It's a bit more complex, but at least it means you can implement the interface correctly. I don't think performance would be a problem, because presumably if HasRows returns true, you're about to start fetching anyway, right? Unless I'm missing something... Dean. ------------------------------------------------------------------------- This SF.net email is sponsored by: Microsoft Defy all challenges. Microsoft(R) Visual Studio 2008. http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/ _______________________________________________ Firebird-net-provider mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/firebird-net-provider
