Information générale
Catégorie:
The Mere Mortals Framework
Titre:
MM 8.1, VFP 8 and Connection Handles
The connection manager in MM v8.1 doesn't appear to be coping with the statement handles that have now appeared in VFP 8. The connection manager appears to be storing the statement handles into the connection array. Since these are all different for each remote view, even when the connection is shared, things appear to going south.
It was fairly easy to modify the connection manager to store the connection handle instead of the statement handle.
But is any if this really necessary? Am I missing something?
* * *
I also needed to apply a patch that Kevin McNeish suggested in some thread somewhere to ensure that the connection manager closes the view first, then disconnects, rather than the other way around. This solved some invalid connection handle problems I was seeing. Has anyone else seen problems along these lines?
Change CDynamicViewCursor.Close() [ in CDataEnv.vcx] from this:
IF TYPE("goConnectionMgr") == "O" AND NOT ISNULL(goConnectionMgr)
IF NOT This.lUseLocalData AND USED(This.Alias) AND ;
CURSORGETPROP("SourceType", This.Alias) = DB_SRCREMOTEVIEW
goConnectionMgr.UnregisterSQLConnection(CURSORGETPROP("ConnectHandle", This.Alias))
ENDIF
ENDIF
RETURN DODEFAULT()
to this:
DODEFAULT()
IF TYPE("goConnectionMgr") == "O" AND NOT ISNULL(goConnectionMgr)
IF NOT This.lUseLocalData AND USED(This.Alias) AND ;
CURSORGETPROP("SourceType", This.Alias) = DB_SRCREMOTEVIEW
goConnectionMgr.UnregisterSQLConnection(CURSORGETPROP("ConnectHandle", This.Alias))
ENDIF
ENDIF
Répondre
Voir le fil de ce thread
Voir le fil de ce thread à partir de ce message seulement
Voir tous les messages de ce thread
Voir tous les messages de ce thread à partir de ce message seulement