Visual Basic - ERROR 40002 VB CAMPO MEMO

Life is soft - evento anual de software empresarial
 
Vista:

ERROR 40002 VB CAMPO MEMO

Publicado por FABIO EDUARDO (1 intervención) el 07/11/2001 02:16:30
En un programa de Visual Basic 6.0, al consultar con SQL un campo MEMO de una base de datos Access para visulaizar los datos en un Textbox aparece el siguiente error: \"Error 40002 en tiempo de ejecución: SL009: [Microsoft] [Bliblioteca de cursores ODBC] No se enlazaron columnas antes de llamar a SQLFetchScroll o SQLExtendedFetch\".

Es de anotar que la misma consulta con otro tipo de dato distinto del MEMO funciona perfectamente.

El siguiente es el código de esta consulta con un campo diferente de MEMO:

\'Mostrar Tipo de identificación

apell = \"SELECT tbtipident.desctipident FROM tbtipident;\"
i = 0
Set RsetDatos = VarConexion.OpenResultset(apell)
With RsetDatos
Do Until .EOF
B = RsetDatos.rdoColumns(0).Value
Combo5.List(i) = B
i = i + 1
.MoveNext
Loop
End With
RsetDatos.Close
Valora esta pregunta
Me gusta: Está pregunta es útil y esta claraNo me gusta: Está pregunta no esta clara o no es útil
0
Responder

ERROR 40002 VB CAMPO MEMO

Publicado por Iván (2 intervenciones) el 12/06/2015 16:52:38
The root cause:

The ODBC driver does not support transactions on a connection that has open sets of results. The result set must be opened and closed within the scope of the transaction. The ODBC driver does not preserve cursors in the transaction boundaries. This means that open result sets, but must be closed before entering or exiting the scope of a transaction. This is a limitation in the design of the ODBC driver used.

Recommended Solutions:

1. Check if there is an ODBC driver that does not have this limitation, and use it if exists.
2. Use DAO instead of RDO.
3. Rewrite the code to avoid this limitation. That is, that the result sets open but closed before entering or exiting the scope of a transaction.

It is not a backend problem, it corresponds to an error in the way you are programming, taking into account the limitations of the ODBC driver used.


Iván.
Valora esta respuesta
Me gusta: Está respuesta es útil y esta claraNo me gusta: Está respuesta no esta clara o no es útil
0
Comentar
sin imagen de perfil
Val: 147
Ha disminuido 1 puesto en Visual Basic (en relación al último mes)
Gráfica de Visual Basic

ERROR 40002 VB CAMPO MEMO

Publicado por Juan Gilberto (323 intervenciones) el 13/06/2015 18:10:36
El problema puede ser el driver que utilizas para conectarte a la bd

Ayudaria si publicaras el codigo donde defines tus varaibles de bd y tablas y donde abres o conectas la bd y las tablas
Valora esta respuesta
Me gusta: Está respuesta es útil y esta claraNo me gusta: Está respuesta no esta clara o no es útil
0
Comentar