||If you return a set of rows from a database table using either the |
SELECT * or
SELECT col1, col2, ..., colN methods and you are retrieving a Memo field you may receive the following error when trying to work with the results of the Memo column:
Microsoft OLE DB Provider for ODBC Drivers error '80020009'
When retrieving a Memo (or blob or text in SQL Server) column from a database, you need to make sure that in the
SELECT list the Memo column comes last. For example, asssume that we have a table in an Access database named
Table1 that has three columns:
Memo). We may get the
8002009 error In our ASP page if we attempt to retrieve information from the table with the following SQL statement:
strSQL = "SELECT Description, Name, Age FROM Table1"
strSQL = "SELECT * FROM Table1"
Instead, we must explicitly specify that the Memo field come at the end of the
SELECT list, like so:
strSQL = "SELECT Name, Age, Description FROM Table1"
For more information on this error be sure to check out:
PRB: 80020009 Error When Retrieving Data from SQL