Disregarding network drive issue "PRAGMA locking_mode=EXCLUSIVE" means
that once your writer requires PENDING or EXCLUSIVE lock nobody else
will be able to read the database anymore until writer closes
connection to it. In other words without this pragma with relatively
small transactions in writer nobody will be able to read database
during small periods of time while writer commits transactions. But
with this pragma you will throw away all readers after the first
commit. I'm not sure you want to do that.

Pavel

On Wed, Oct 21, 2009 at 3:44 AM, Jan <janus...@gmx.net> wrote:
> Hi,
>
> Although I read in a recent post by drh that it is not recommended to
> use sqlite in a local network I would like to ask if the following
> approach would work:
>
> A database in the local network needs to be accessed by about 20 people.
> I suppose the max. number at the same time will be 4-5. Only one is able
> to write to the database at the same time. The one who wants to write to
> the database acquires an exclusive look with "PRAGMA
> locking_mode=EXCLUSIVE" if locking_mode is currently NORMAL. AFAIR all
> others should then still be able to read, but not to write.
>
> Is that correct and more or less save? Does anyone have experience with
> sqlite on a networkdrive?
>
> Thank you
> Jan
> _______________________________________________
> sqlite-users mailing list
> sqlite-users@sqlite.org
> http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users
>
_______________________________________________
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Reply via email to