Re: Forward-only recordsets



JohnnyC wrote:
I've got a strange problem with a forward-only recordset.

The front-end is an ASP web. The backend is a sql2005 database.

In the code, there are sql statements using '*'. For example "select
* from tableA"

This is pretty universally regarded as a bad practice in production
code: http://www.aspfaq.com/show.asp?id=2096

The recordset is populated using the
connection.execute method. i.e. set rs = conn.execute(sql)

When referencing the fields in the recordset, if they are not
referenced in the same order as the underlying table, we are getting
blanks returned. If I use explicit field names in the sql call, it
doesn't matter the order of how we read the rs fields.

It may be an issue with the datatypes. Are you using ODBC and are Text
or Image columns involved?

--
Microsoft MVP -- ASP/ASP.NET
Please reply to the newsgroup. The email account listed in my From
header is my spam trap, so I don't check it very often. You will get a
quicker response by posting to the newsgroup.


.



Relevant Pages

  • Re: Forward-only recordsets
    ... there are sql statements using '*'. ... When referencing the fields in the recordset, ... It may be an issue with the datatypes. ... Please reply to the newsgroup. ...
    (microsoft.public.data.ado)
  • RE: Designing My App for Seed!
    ... You will not gain speed by changing your queries to SQL Statements as ... Split the application and database into front and back-ends, ... However, using, Microsoft Sans Serif in applications, make fonts ...
    (microsoft.public.access.tablesdbdesign)
  • RE: Blocking sql statement?
    ... Some sql statements I send to the database contain some invisible ... The data changes about every 3 hours - ... > me some information about debugging a SQLServerCE? ...
    (microsoft.public.sqlserver.ce)
  • RE: two sql statement questions
    ... even if you're connecting to a database through ... Not all database supports multiple SQL statements. ... Microsoft Online Community Support ... Engineer within 1 business day is acceptable. ...
    (microsoft.public.data.odbc)
  • Re: OO Design, Physical Implementation, DAOs
    ... > of DataAdapter objects, Command objects, and sql statements which are ... > instruction/examples on the proper way to construct the DAL? ... particular database if you're not careful. ...
    (comp.object)