Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

SQL Server mobile 2005 and multithreading

17 views
Skip to first unread message

Roman

unread,
Aug 30, 2006, 4:43:04 AM8/30/06
to
I have a class with static methods in my application which handles my
database connection objects. Now we had sometimes errors while database
access and the application stucks completely. If I check the call stack
there are always native methods of SQL server mobile where the
allication hang. Only a reset of the device can help.
We use multithreading and it can happen that two different threads are
using the same connection object (if its open or closed before). I
think this could cause this error but I am not sure. Is this allowed or
shoud we generate different connection objects for differen threads.

Thanks
Roman

Ginny Caughey [MVP]

unread,
Aug 30, 2006, 5:50:13 AM8/30/06
to
Roman,

I think it's likely that using the same connection object on multiple
threads is causing your problem. The first thing I'd try is using separate
connections for each thread.

--
Ginny Caughey
Device Application Development MVP


"Roman" <roman.mel...@info-research.ch> wrote in message
news:1156927384.3...@h48g2000cwc.googlegroups.com...

Roman

unread,
Aug 30, 2006, 7:19:08 AM8/30/06
to
Is there some 'best practice' proposal about connection handling with
sql server mobile 2005 from microsoft?

Roman

Ginny Caughey [MVP]

unread,
Aug 30, 2006, 4:34:30 PM8/30/06
to
Roman,

Not that I'm aware of.

--
Ginny Caughey
Device Application Development MVP


"Roman" <roman.mel...@info-research.ch> wrote in message

news:1156936748.7...@m79g2000cwm.googlegroups.com...

0 new messages