On Wed, May 26, 2010 at 8:15 PM, jdee5 <jonidm...@yahoo.com> wrote:
>
>
>
> Thanks for your reply.  I have read through the link you suggested, very
> helpful...if I may ask another question concerning this.  Say on my
> application I have 2 users reading some of the database contents at the same
> time and they both log something in my application at the same time.  For
> example say they want to both review different customer accounts and add a
> payment to the different customer accounts.  Would there be a delay with
> both of those when using SQLite, if so would it be significant?
>
> Can I use SQLite this way have my application stored on the server and allow
> users on a LAN/peer to peer have the ability to open my app and write to it
> at the same time?  does this type of multi user access often corrupt the
> database?  If my database does become corrupt how can I repair it.
>
> Sorry for the redudancy in the questions...like I said am new to SQL (used
> MS SQL a little) and really new to the idea of using an embedded database
> engine.


Why do you want to use an "embedded database engine" and want to have
multiple concurrent users changing the db over a network? If you want
to users to be able to change stuff at the same time from different
locations, use a true client/server db such as Postgres or MySQL.

If you have only a few users who will be changing the data, you could
create a SQLite-powered web app, but there could be potential
instances of lockouts. If you want to put your db on a LAN (shared
disk), and have remote users change it, there is likely a potential
for db to be corrupted.



>
> Thanks in advance for information
>
>
>
> Simon Slavin-3 wrote:
>>
>>
>> On 26 May 2010, at 10:04pm, jdee5 wrote:
>>
>>> I am looking for an SQL engine that is easy to install and sqlite seems
>>> like
>>> the right way to go.  I have an application (currently just for network
>>> use
>>> on a LAN) and I want to move to using SQL, my application is fairly small
>>> and simple and I like the idea of embedding SQL and using SQLite so my
>>> end
>>> user doesn't notice any difference from my current application...however,
>>> more than 1 person may want to access the db at a time does SQLite allow
>>> for
>>> this?
>>
>> Yes.  SQLite supports locking for multi-user and multi-process access.  It
>> is unusual in that it locks the entire database file rather than
>> individual records, but the SQLite calls you make handle multi-user access
>> correctly.  You /will/ have to make your application aware of how to
>> handle the errors which arise if one user keeps the database locked so
>> long that the other user can't access it.  I recommend you read this page
>> (though you don't have to memorise it all):
>>
>> <http://www.sqlite.org/lockingv3.html>
>>
>>> Can it just sequentially record transactions as they are made even if
>>> made simultaneously... I have search all over and can't come to a clear
>>> conclusion, I am also very new to using SQL.
>>
>> Under most circumstances, even if two programs are entering transactions
>> at the same time, SQLite will handle this without the programs having to
>> be aware of it.  However, make sure you handle the SQLITE_BUSY and
>> SQLITE_LOCKED errors correctly.  I hope someone can recommend a page which
>> breaks down how to do this.
>>
>> Simon.
>> _______________________________________________
>> sqlite-users mailing list
>> sqlite-users@sqlite.org
>> http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users
>>
>>
>
> --
> View this message in context: 
> http://old.nabble.com/Novice-SQLite-user-tp28686380p28688425.html
> Sent from the SQLite mailing list archive at Nabble.com.
>
> _______________________________________________
> sqlite-users mailing list
> sqlite-users@sqlite.org
> http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users
>



-- 
Puneet Kishor http://www.punkish.org
Carbon Model http://carbonmodel.org
Charter Member, Open Source Geospatial Foundation http://www.osgeo.org
Science Commons Fellow, http://sciencecommons.org/about/whoweare/kishor
Nelson Institute, UW-Madison http://www.nelson.wisc.edu
-----------------------------------------------------------------------
Assertions are politics; backing up assertions with evidence is science
=======================================================================
_______________________________________________
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Reply via email to