Cannot execute select statement 
Author Message
 Cannot execute select statement

I'm using vb to access a mysql database.

The connection works perfectly and using DAO to loop through the records
also works.

What I'm having a problem with is selecting records with SQL.

I have the following snippit that is generating a 3065 error (Cannot execute
select statement)

dim SQL as string
SQL = "SELECT * FROM stores"
db.execute SQL

Any suggestions on how to rectify this problem?

Douglas

NOTICE: REMOVE NO and SPAM from email address when replying.



Sat, 20 Nov 2004 00:32:25 GMT  
 Cannot execute select statement
You need to populate a recordset, with something like:

Dim rst As RecordSet

Quote:
>dim SQL as string
>SQL = "SELECT * FROM stores"

rst.Open SQL, strConnection

HTH

--- Andy



Sat, 20 Nov 2004 20:11:03 GMT  
 Cannot execute select statement
On Mon, 03 Jun 2002 16:32:25 GMT, "Douglas W. Palme"
Hi

you cannot perform an execution on a SELECT statement

Mark

Quote:
>I'm using vb to access a mysql database.

>The connection works perfectly and using DAO to loop through the records
>also works.

>What I'm having a problem with is selecting records with SQL.

>I have the following snippit that is generating a 3065 error (Cannot execute
>select statement)

>dim SQL as string
>SQL = "SELECT * FROM stores"
>db.execute SQL

>Any suggestions on how to rectify this problem?

>Douglas

>NOTICE: REMOVE NO and SPAM from email address when replying.



Sun, 21 Nov 2004 15:38:41 GMT  
 
 [ 3 post ] 

 Relevant Pages 

1. Progress of an executing SELECT statement?

2. Select * vs Execute Statement

3. executing SELECT statement with return value from other stored procedure

4. Very simple - How to execute sub statements before the end statement

5. How to select the current record only with SELECT statement

6. cannot execute MDE

7. One workstation cannot open or execute VBA code in Access 97

8. Runtime error 4633 cannot execute macro

9. Cannot execute as a child of basic

10. Cannot execute SHAPE command on ADO recordset

11. Cannot execute ftp commands using Inet

12. Cannot execute SHAPE command on ADO recordset

 

 
Powered by phpBB® Forum Software