From: SourceForge.net <no...@so...> - 2006-08-19 16:18:15
|
Bugs item #1474021, was opened at 2006-04-21 05:59 Message generated for change (Comment added) made by redi You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=107869&aid=1474021&group_id=7869 Please note that this message will contain a full copy of the comment thread, including the initial issue submission, for this request, not just the latest update. Category: None Group: None Status: Open Resolution: None Priority: 5 Submitted By: Nobody/Anonymous (nobody) Assigned to: Nobody/Anonymous (nobody) Summary: Multithreading Initial Comment: Let's consdier sample case. I have a simple program that starts numerous threads. In thread routine I create Connection object and try to connect to database. The problem is that in Connection objects MYSQL* are equal so I ve got errors. ---------------------------------------------------------------------- >Comment By: Jonathan Wakely (redi) Date: 2006-08-19 16:18 Message: Logged In: YES user_id=426241 (sorry for the late reply) You haven't given enough information to know what's wrong. If you share a Connection between threads you will have a problem (this includes taking copies of an existing Connection) If you create a new Connection in each thread it should work. You might want to look at mysql++ instead - recently it's more actively developed and supported than mysqlcppapi ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=107869&aid=1474021&group_id=7869 |