Re: Sharing a ADO connection between two processes - Can it be done ?
- From: Paul Clement <UseAdddressAtEndofMessage@xxxxxxxxxxxxxx>
- Date: Mon, 02 Oct 2006 08:55:23 -0500
On 2 Oct 2006 04:14:29 -0700, "Herby" <prmarjoram@xxxxxxxxx> wrote:
¤ We have a client and server application that run on the same machine.
¤ We want both to participate in the same transaction.
¤
¤ To acheive this I understand they need to share the same connection
¤ object.
¤
¤ The server currently supports a COM interface, as the client passes
¤ across copies of simple data types Strings and integers etc.
¤
¤ But now they want to pass across the client ADO connection object. The
¤ data-writes within the server should then use this connection object
¤ for creating its recordsets etc.
¤
¤ On return to the client - the client may then decide to commit or
¤ rollback via the same connection object.
¤
¤ I understand the server would have a proxy back to the actual
¤ connection object residing in the client address space. Is this going
¤ to work?
No don't do this. ADO Connection objects do not marshal properly across processes.
Your data access layer should be handling the transaction. I don't see any reason for the
transaction to occur across processes. However, it you want the client to determine whether the
transaction is committed or rolled back you may want to consider using COM+.
Paul
~~~~
Microsoft MVP (Visual Basic)
.
- Follow-Ups:
- References:
- Prev by Date: Sharing a ADO connection between two processes - Can it be done ?
- Next by Date: Re: Sharing a ADO connection between two processes - Can it be done ?
- Previous by thread: Sharing a ADO connection between two processes - Can it be done ?
- Next by thread: Re: Sharing a ADO connection between two processes - Can it be done ?
- Index(es):
Relevant Pages
|