Description:
I'M using VB 6 SP5 to make a test application. I created an ADO Recordset to access a MySQL 4.0.13-max table and update it.
The cursor location propertie of the recordset was seted to adUseServer.
The recordset was opened succesfully and it can be browsed without problems.
When i tried to update a recordset, first i do an Adodc1.Recordset.Move 0, but an error " -2147467259 (80004005) [MySQL][ODBC 3.51 Driver][mysqld-4-0.13-max] You have an error in your SQL syntax. Check the manual that corresponds to your MySQL server version for the right syntax to use near 'DEFAULT VALUES' at line 1" occurs.
The myodbc log is :
| >do_query
| | >mysql_real_query
| | | enter: handle: 22e00c
| | | query: Query = "INSERT INTO pvcl00 DEFAULT VALUES"
| | | >vio_is_blocking
| | | | exit: 1
| | | <vio_is_blocking
| | | >vio_blocking
| | | | enter: set_blocking_mode: 0
| | | <vio_blocking
| | | >vio_is_blocking
| | | | exit: 1
| | | <vio_is_blocking
| | | >net_flush
| | | | >vio_is_blocking
| | | | | exit: 1
| | | | <vio_is_blocking
| | | | >net_real_write
| | | | | >vio_write
| | | | | | enter: sd=688 size=38
| | | | | | exit: 38
| | | | | <vio_write
| | | | <net_real_write
| | | <net_flush
| | <mysql_real_query
| | >mysql_read_query_result
| | | >vio_is_blocking
| | | | exit: 1
| | | <vio_is_blocking
| | | >vio_read
| | | | enter: sd=688 size=4
| | | | exit: 4
| | | <vio_read
| | | >vio_read
| | | | enter: sd=688 size=164
| | | | exit: 164
| | | <vio_read
| | | error: Got error: 1064 (You have an error in your SQL syntax. Check the manual that corresponds to your MySQL server version for the right syntax to use near 'DEFAULT VALUES' at line 1)
| | <mysql_read_query_result
| | >set_stmt_error
| | | error: message: You have an error in your SQL syntax. Check the manual that corresponds to your MySQL server version for the right syntax to use near 'DEFAULT VALUES' at line 1
| | | exit : SQL_ERROR
| | <set_stmt_error
| | exit : SQL_ERROR
| <do_query
| exit : SQL_ERROR
<SQLExecute
>SQLGetDiagField
| values: 3,0x227020,1,4,0x3601db0,12,0x12ecb6
| exit : SQL_SUCCESS
<SQLGetDiagField
>SQLGetDiagField
| values: 3,0x227020,2,4,0x3601db0,12,0x12ecb6
| exit : SQL_NO_DATA_FOUND
<SQLGetDiagField
>SQLGetDiagRec
| values: 3,0x227020,1,0x12ec5c,0x12f0fc,0x36058d0,512,0x12f100
<SQLGetDiagRec
>SQLGetDiagRec
| values: 3,0x227020,2,0x12ec5c,0x12f0fc,0x36058d0,512,0x12f100
| exit : SQL_NO_DATA_FOUND
<SQLGetDiagRec
>my_SQLDisconnect
| >mysql_close
| | >free_old_query
| | <free_old_query
| | >vio_is_blocking
| | | exit: 1
| | <vio_is_blocking
| | >vio_blocking
| | | enter: set_blocking_mode: 0
| | <vio_blocking
| | >vio_is_blocking
| | | exit: 1
| | <vio_is_blocking
| | >net_flush
| | | >vio_is_blocking
| | | | exit: 1
| | | <vio_is_blocking
| | | >net_real_write
| | | | >vio_write
| | | | | enter: sd=1016 size=5
| | | | | exit: 5
| | | | <vio_write
| | | <net_real_write
| | <net_flush
| | >end_server
| | | info: Net: TCP/IP (1016)
| | | >vio_close
| | | <vio_close
| | | >_myfree
| | | | enter: ptr: 3fd2118
| | | <_myfree
| | | >_myfree
| | | | enter: ptr: 4470740
| | | <_myfree
| | | >free_old_query
| | | <free_old_query
| | <end_server
| | >_myfree
| | | enter: ptr: 3fd2078
| | <_myfree
| | >_myfree
| | | enter: ptr: 3fd2628
| | <_myfree
| | >_myfree
| | | enter: ptr: 3fd4fe8
| | <_myfree
| | >_myfree
| | | enter: ptr: 3fd4f98
| | <_myfree
| | >_myfree
| | | enter: ptr: 0
| | <_myfree
| | >_myfree
| | | enter: ptr: 0
| | <_myfree
| | >_myfree
| | | enter: ptr: 0
| | <_myfree
| | >_myfree
| | | enter: ptr: 0
| | <_myfree
| | >_myfree
| | | enter: ptr: 0
| | <_myfree
| | >_myfree
| | | enter: ptr: 0
| | <_myfree
| | >_myfree
| | | enter: ptr: 0
| | <_myfree
| | >_myfree
| | | enter: ptr: 0
| | <_myfree
| | >_myfree
| | | enter: ptr: 0
| | <_myfree
| | >_myfree
| | | enter: ptr: 0
| | <_myfree
| <mysql_close
| >_myfree
| | enter: ptr: 3fd4f48
| <_myfree
| >_myfree
| | enter: ptr: 3fd4ef8
| <_myfree
| >_myfree
| | enter: ptr: 3fd4e98
| <_myfree
| >_myfree
| | enter: ptr: 3fd4e48
| <_myfree
| >_myfree
| | enter: ptr: 3fd4df8
| <_myfree
| exit : SQL_SUCCESS
<my_SQLDisconnect
>SQLFreeConnect
| >_myfree
| | enter: ptr: 0
| <_myfree
| >_myfree
| | enter: ptr: 0
| <_myfree
| >_myfree
| | enter: ptr: 0
| <_myfree
| >_myfree
| | enter: ptr: 0
| <_myfree
| >_myfree
| | enter: ptr: 0
| <_myfree
| exit : SQL_SUCCESS
<SQLFreeConnect
How to repeat:
Create an ado connection to a table on mysql - open it and do and adodc1.recordset.move 0