>>
>>Avanzando,,, I created a DNS with the VFP ODBC driver as you suggested and added a connection to the second DBC pointing to the new DNS. The connection tested succesfully, but the following test code does not seem to work.
>>
>>
>>SET DATABASE TO dacilsa
>>lnhandle = SQLCONNECT('coneccion_dacilsa')
>>lcCommand = [UPDATE Accounts SET Desc = ALLTRIM(Desc) + ' cambiado' WHERE Number = '100 ']
>>?SQLEXEC(lnhandle,lcCommand)
>>
>>
>>What can be the problem?
>>
>>Alex
>
>Is Number a character column?
>
>Anyway, you can check the error report from the ODBC driver by inspecting the error array after an AERROR().
>
>LOCAL ARRAY laError(1)
>... your code ...
>
>IF SQLEXEC(m.lnHandle,m.lcCommand)=-1
> AERROR(m.laError)
> IF m.laError(1,1) = 1526
> FOR m.lnLoop = 1 TO ALEN(m.laError,1)
> ? m.laError(m.lnLoop,3)
> ENDFOR
> ENDIF
>ENDIF
>
>(not tested - see AERROR() in Help for more details).
Thank you Antonio. The values in the array are:
1526
"Connectivity error: [Microsoft][ODBC Visual FoxPro Driver]Syntax error."
"[Microsoft][ODBC Visual FoxPro Driver]Syntax error."
"37000"
200
3
.NULL.
I am not sure what the syntax error may be. I'll continue tomorrow. It's 3:30am here.
Thanks a lot for the help.
Alex