Retrieving Fields from RecordSet (Order of retriev

Results 1 to 2 of 2

Thread: Retrieving Fields from RecordSet (Order of retriev

  1. #1
    Join Date
    Dec 1969

    Default Retrieving Fields from RecordSet (Order of retriev

    Hi,<BR><BR>I am writing a page to just retrieve the data from a database that contains info of a list of CDs (CD name, format, release date, price, etc)<BR>and I found out that the order of retrieving fields from a record set affect the result of showing the fields.<BR>That is, sometimes if I retrieve the CD name first, the format and price cannot be retrieve. I have to test the order of retrieving the fields to be able to get all the fields out.<BR><BR>For example, if I am doing this:<BR><BR>Response.Write rs.Fields("CDname")<BR>Response.Write rs.Fields("format")<BR>Response.Write rs.Fields("price")<BR>Response.Write rs.Fields("releaseDate")<BR><BR>then maybe only the CDname can be printed out and the other fields are all empty, but if I change the ordering to be like this:<BR><BR>Response.Write rs.Fields("releaseDate")<BR>Response.Write rs.Fields("CDname")<BR>Response.Write rs.Fields("price")<BR>Response.Write rs.Fields("format")<BR><BR>then all of the fields can be printed.<BR>Does anyone know what the problem is? I got this problem many many times already while writing my site, please HELP!<BR><BR>Thanks in advance.<BR><BR>TChoi<BR><BR>

  2. #2
    Join Date
    Dec 1969

    Default Happens when one field is a Memo

    ...or, in SQL Server, a Text or nText field.<BR><BR>This *IS* documented in the ASPFAQs (there&#039;s a link to them at the top right corner of this very page), I believe in the category "Databases, Errors" (but if not, then in one of the other Databases categories).<BR><BR>Read the instructions there on how to best treat the problem.<BR><BR>I have also *heard* that the problem is lessened and/or gone with the latest version of ADO (version 2.7 or 2.8). You might try installing the latest version to see if it helps.<BR><BR>

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts