Re: RecordSet fails if a field is null ! - unspecified error '80004005'

Tech-Archive recommends: Fix windows errors by optimizing your registry



Dan wrote:
Bob Barrows [MVP] wrote:
Troubled User wrote:
Heres a good one.

I have my ado stuff in a class, so that I don't have to deal with it
in my code.

In the class.FetchRows function I do the following

Set rs = Server.CreateObject("ADODB.RecordSet")
rs.Open strSQLStatement, DBConn
aryRows = rs.GetRows()


This statement will raise an error if rs.eof is true. Always test
for eof before using GetRows or GetString:
if not rs.eof then aryRows = rs.GetRows()

For this case i dont think that bof/eof is the problem.

:-)
I didn't say it was, did I? I was just covering all the bases. When I see
sombody doing something that may cause them problems in the future, I like
to point that out. It's called "being helpful".

If i copy and
paste the same string into ms Access It returns the row that I
expected. Also, If i simple change the field from origin to something
that i know has data in it, then i don't get this error message.
I didnt think that eof was a problem with get rows. I'll assume that
you know more then me about that then I do, so ill just add that in
anyway.'


Well, if you're going to get snotty about it ...


--
Microsoft MVP - ASP/ASP.NET
Please reply to the newsgroup. This email account is my spam trap so I
don't check it very often. If you must reply off-line, then remove the
"NO SPAM"


.



Relevant Pages

  • Re: Delete a single record instead of entire recordset
    ... Please reply to the newsgroup. ... Depends on the text of the error message. ... The email account listed in my From ... header is my spam trap, so I don't check it very often. ...
    (microsoft.public.data.ado)
  • Re: Best to use On Error Resume Next all the time?
    ... Laphan wrote: ... > MySQL, MS SQL, etc) doesn't blurt out an error message, which could ... > have sensitive info such as table names, db names, etc, to your ASP ... This email account is my spam trap so I ...
    (microsoft.public.inetserver.asp.db)
  • Re: Best to use On Error Resume Next all the time?
    ... Laphan wrote: ... > MySQL, MS SQL, etc) doesn't blurt out an error message, which could ... > have sensitive info such as table names, db names, etc, to your ASP ... This email account is my spam trap so I ...
    (microsoft.public.inetserver.asp.db)
  • Re: Connect SQL server issue
    ... Are there any place to find the ASP methods and properties information? ... >> Error message is following: ... > You only need an explicit Command object if passing parameters to a stored ... This email account is my spam trap so I ...
    (microsoft.public.inetserver.asp.db)
  • Re: Connect SQL server issue
    ... > Error message is following: ... set conn = Server.CreateObject ... You only need an explicit Command object if passing parameters to a stored ... This email account is my spam trap so I ...
    (microsoft.public.inetserver.asp.db)