Article View: borland.public.cppbuilder.database.multi-tier
Article #1041Database connections
From: Jinny
Date: Wed, 12 Jul 2000 00:00
Date: Wed, 12 Jul 2000 00:00
17 lines
1488 bytes
1488 bytes
I am doing two-tier database application by C++ Builder 5.0 with MS Access 2000 and MS SQL server by ODBC. The question I have is if two or more instances of my database application from different machines try to access the same table of the database, only one of them is allowed to modify the data, others just can read data. Is there a mechanism to handle such situation. I understand that when the applications try to access the database, a connection is setup for each application with the database. Is there a way that before a application accesses to the database, it check the connection of the database, if there is more that one connection with the database, the application just allows its Data Controls Components to read the data; After the application which could modify the data (i.e. first application accesses to the database) closes or crashes, it release its connection with database, then the other application could access to the database and modify the data? Thank you!
Technical Details
Message-ID:
<396c042b@dnews>Path:
arc1-ca.pugleaf.net!unknown!not-for-mailShow Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: fcd2b,200ad17980a3a49b,start X-Google-Attributes: gidfcd2b,public From: "Jinny" <jin.luo@quest.com.au> Subject: Database connections Date: 2000/07/12 Message-ID: <396c042b@dnews> X-Deja-AN: 645350943 X-Trace: 11 Jul 2000 22:37:47 -0800, 203.12.165.115 X-MSMail-Priority: Normal X-Priority: 3 Newsgroups: borland.public.cppbuilder.database.multi-tier X-MimeOLE: Produced By Microsoft MimeOLE V5.00.2314.1300