4 Replies Latest reply: Feb 1, 2007 6:39 AM by Newsgroup_User RSS

    ADODB.Field error '800a0bcd' help!

    Mal9
      Hi there, I have been trying to figure out why this message has been coming up for days.

      ADODB.Field error '800a0bcd'
      Either BOF or EOF is True, or the current record has been deleted. Requested operation requires a current record.
      /html/product.asp, line 276

      Which reads

      Code: <%=(rsSupplier.Fields.Item("Supplier").Value)%>

      I have just discovered that all the entries with a "&" in it come up with this error.

      The data is in the database for sure.

      Is it something to do with the database or is it my poor coding.

      Cheers
        • 1. Re: ADODB.Field error '800a0bcd' help!
          Mal9 Community Member
          Some code:

          <%
          Dim rsSearchResult
          Dim rsSearchResult_numRows
          Set rsSearchResult = Server.CreateObject("ADODB.Recordset")
          rsSearchResult.ActiveConnection = MM_conn_STRING
          rsSearchResult.Source = "SELECT SupplierName, ContactName, FamilyName FROM tblone WHERE Timber LIKE '%" + Replace(rsSearchResult__MMColParam, "'", "''") + "%' AND Category LIKE '%" + Replace(rsSearchResult__MMColParam2, "'", "''") + "%' AND Location LIKE '%" + Replace(rsSearchResult__MMColParam3, "'", "''") + "%' AND Customer = 'Trade/Retail' ORDER BY Category, Timber ASC"
          rsSearchResult.CursorType = 0
          rsSearchResult.CursorLocation = 2
          rsSearchResult.LockType = 1
          rsSearchResult.Open()
          rsSearchResult_numRows = 0
          %>
          • 2. Re: ADODB.Field error '800a0bcd' help!
            Community Member
            Ampersands need to be escaped. You can use the built-in Server.URLEncode to
            escape all characters that might cause problems parsing the resulting URL
            when you're building your link.
            Ex: <a
            href="somePage.asp?someVal=<%=Server.URLEncode(myRS.Fields.Item("something").Value)%>">Li nk</a>


            "Mal9" <webforumsuser@macromedia.com> wrote in message
            news:eppit8$6cp$1@forums.macromedia.com...
            > Hi there, I have been trying to figure out why this message has been
            > coming up
            > for days.
            >
            > ADODB.Field error '800a0bcd'
            > Either BOF or EOF is True, or the current record has been deleted.
            > Requested
            > operation requires a current record.
            > /html/product.asp, line 276
            >
            > Which reads
            >
            > Code: <%=(rsSupplier.Fields.Item("Supplier").Value)%>
            >
            > I have just discovered that all the entries with a "&" in it come up with
            > this
            > error.
            >
            > The data is in the database for sure.
            >
            > Is it something to do with the database or is it my poor coding.
            >
            > Cheers
            >
            >


            • 3. Re: ADODB.Field error '800a0bcd' help!
              Mal9 Community Member
              Ok I see. Excuse my ignorance, could you use the follwing as an example.

              <%=(rsSupplier.Fields.Item("SupplierName").Value)%>

              Cheers
              Malcolm
              • 4. Re: ADODB.Field error '800a0bcd' help!
                Community Member
                Type Server.URLEncode between the = and the (

                "Mal9" <webforumsuser@macromedia.com> wrote in message
                news:epq8uh$2s8$1@forums.macromedia.com...
                > Ok I see. Excuse my ignorance, could you use the follwing as an example.
                >
                > <%=(rsSupplier.Fields.Item("SupplierName").Value)%>
                >
                > Cheers
                > Malcolm