Solved

Accessing DAO from multiple threads

Posted on 1998-08-20
3
171 Views
Last Modified: 2013-11-20
I have implemented a DAO class in a dll that is being used by a console application. Now the console application is multi-threaded and I am getting an exception trying to open the database from multiple threads. I would like to maintain accessing from multiple threads. Is there a way out?
0
Comment
Question by:sjohnv
3 Comments
 
LVL 8

Expert Comment

by:trestan
ID: 1321076
I think you need to use semaphore and wait functions to control the synchronization object.
0
 
LVL 2

Accepted Solution

by:
Paullkha earned 50 total points
ID: 1321077
DAO (most versions) should not be used in multithreaded environments. Please check article ID: Q151407 from MS.
0
 

Expert Comment

by:mmachie
ID: 1321078
there is an article on www.codeguru.com with info on dao and multi threading.  i haven't read it, just seen the entry for it under databases.
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Running shell command from Access 3 68
Importing Special Characters in Dynamics GP Through Integration Manager 3 69
string initialization in java 11 109
modThree challenge 4 76
Introduction: Finishing the grid – keyboard support for arrow keys to manoeuvre, entering the numbers.  The PreTranslateMessage function is to be used to intercept and respond to keyboard events. Continuing from the fourth article about sudoku. …
Introduction: Hints for the grid button.  Nested classes, templated collections.  Squash that darned bug! Continuing from the sixth article about sudoku.   Open the project in visual studio. First we will finish with the SUD_SETVALUE messa…
This video will show you how to get GIT to work in Eclipse.   It will walk you through how to install the EGit plugin in eclipse and how to checkout an existing repository.
This video demonstrates how to create an example email signature rule for a department in a company using CodeTwo Exchange Rules. The signature will be inserted beneath users' latest emails in conversations and will be displayed in users' Sent Items…

932 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

12 Experts available now in Live!

Get 1:1 Help Now