[sqlite] SQLite error(5): database is locked in System.Data.SQLite

2015-03-04 Thread Drago, William @ CSG - NARDA-MITEQ
There is some info here:

http://sqlite.org/threadsafe.html

--
Bill Drago
Senior Engineer
L3 Narda-MITEQ
435 Moreland Road
Hauppauge, NY 11788
631-272-5947 / William.Drago at L-3COM.com



> -Original Message-
> From: sqlite-users-bounces at mailinglists.sqlite.org [mailto:sqlite-
> users-bounces at mailinglists.sqlite.org] On Behalf Of Hick Gunter
> Sent: Wednesday, March 04, 2015 8:45 AM
> To: 'General Discussion of SQLite Database'
> Subject: Re: [sqlite] SQLite error(5): database is locked in
> System.Data.SQLite
>
> Only one writer may be active at any one time. The other(s) will
> recieve an error return status. You can either wait a while and retry
> this in your application or set a busy timeout to handle the "usual"
> cases for you.
>
> -Urspr?ngliche Nachricht-
> Von: Rohit Savaliya [mailto:rohit.savaliya at matrixcomsec.com]
> Gesendet: Mittwoch, 04. M?rz 2015 07:46
> An: sqlite-users at mailinglists.sqlite.org
> Betreff: [sqlite] SQLite error(5): database is locked in
> System.Data.SQLite
>
> Hi all,
>
> I am using System.Data.SQLite in my project.
> I have two threads which are updating database simultaneously.
> I get SQLite error(5): database is locked, System.Data.SQLite error.
>
> Why is it so!. What could be the reason? Does System.Data.SQLite is not
> thread safe?
> Please help me out.
>
> --
> Regards
> Rohit Savaliya
> ___
> sqlite-users mailing list
> sqlite-users at mailinglists.sqlite.org
> http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users
>
>
> ___
>  Gunter Hick
> Software Engineer
> Scientific Games International GmbH
> FN 157284 a, HG Wien
> Klitschgasse 2-4, A-1130 Vienna, Austria
> Tel: +43 1 80100 0
> E-Mail: hick at scigames.at
>
> This communication (including any attachments) is intended for the use
> of the intended recipient(s) only and may contain information that is
> confidential, privileged or legally protected. Any unauthorized use or
> dissemination of this communication is strictly prohibited. If you have
> received this communication in error, please immediately notify the
> sender by return e-mail message and delete all copies of the original
> communication. Thank you for your cooperation.
>
>
> ___
> sqlite-users mailing list
> sqlite-users at mailinglists.sqlite.org
> http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users
CONFIDENTIALITY, EXPORT CONTROL AND DISCLAIMER NOTE:This e-mail and any 
attachments are solely for the use of the addressee and may contain information 
that is privileged or confidential. Any disclosure, use or distribution of the 
information contained herein is prohibited. In the event this e-mail contains 
technical data within the definition of the International Traffic in Arms 
Regulations or Export Administration Regulations, it is subject to the export 
control laws of the U.S.Government. The recipient should check this e-mail and 
any attachments for the presence of viruses as L-3 does not accept any 
liability associated with the transmission of this e-mail. If you have received 
this communication in error, please notify the sender by reply e-mail and 
immediately delete this message and any attachments.


[sqlite] SQLite error(5): database is locked in System.Data.SQLite

2015-03-04 Thread Simon Slavin

On 4 Mar 2015, at 1:45pm, Hick Gunter  wrote:

> Only one writer may be active at any one time. The other(s) will recieve an 
> error return status. You can either wait a while and retry this in your 
> application or set a busy timeout to handle the "usual" cases for you.

Agreed.  The default timeout for SQLite is zero, which means that the first 
time both threads try to access the database at the same time an error will 
occur.  Setting a retry time will fix this.

If someone is using System.Data.SQLite how do they set a busy timeout ?  Do 
they have access to the C function or the PRAGMA ?

Simon.


[sqlite] SQLite error(5): database is locked in System.Data.SQLite

2015-03-04 Thread Hick Gunter
Only one writer may be active at any one time. The other(s) will recieve an 
error return status. You can either wait a while and retry this in your 
application or set a busy timeout to handle the "usual" cases for you.

-Urspr?ngliche Nachricht-
Von: Rohit Savaliya [mailto:rohit.savaliya at matrixcomsec.com]
Gesendet: Mittwoch, 04. M?rz 2015 07:46
An: sqlite-users at mailinglists.sqlite.org
Betreff: [sqlite] SQLite error(5): database is locked in System.Data.SQLite

Hi all,

I am using System.Data.SQLite in my project.
I have two threads which are updating database simultaneously.
I get SQLite error(5): database is locked, System.Data.SQLite error.

Why is it so!. What could be the reason? Does System.Data.SQLite is not thread 
safe?
Please help me out.

--
Regards
Rohit Savaliya
___
sqlite-users mailing list
sqlite-users at mailinglists.sqlite.org
http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users


___
 Gunter Hick
Software Engineer
Scientific Games International GmbH
FN 157284 a, HG Wien
Klitschgasse 2-4, A-1130 Vienna, Austria
Tel: +43 1 80100 0
E-Mail: hick at scigames.at

This communication (including any attachments) is intended for the use of the 
intended recipient(s) only and may contain information that is confidential, 
privileged or legally protected. Any unauthorized use or dissemination of this 
communication is strictly prohibited. If you have received this communication 
in error, please immediately notify the sender by return e-mail message and 
delete all copies of the original communication. Thank you for your cooperation.




[sqlite] SQLite error(5): database is locked in System.Data.SQLite

2015-03-04 Thread Rohit Savaliya
Hi all,

I am using System.Data.SQLite in my project.
I have two threads which are updating database simultaneously.
I get SQLite error(5): database is locked, System.Data.SQLite error.

Why is it so!. What could be the reason? Does System.Data.SQLite is not
thread safe?
Please help me out.

-- 
Regards
Rohit Savaliya