Using SQLite as a multi-user database?

Andre Garzia andre at andregarzia.com
Tue Nov 23 12:18:43 EST 2010


you can keep connections open, as many as you think is reasonable, so if two
client connects you can loop thru the connected clients answering their
requests in a merry go round fashion.

the only times where LiveCode will fail to answer a connection is if there
is some blocking code running and at the little milliseconds interval while
it is accepting the connection.

so, to answer your specific "Or is LiveCode capable somehow of communicating
on multiple sockets simultaneously?" it is capable of sustaining multiple
connection but it will talk to only one at a time, so you need to loop
talking to everybody.



On Tue, Nov 23, 2010 at 2:51 PM, Bob Sneidar <bobs at twft.com> wrote:

> Andre. How would you que the requests? Since LiveCode is not multithreaded,
> what would happen if 2 clients made a request simultaneously? You still have
> the same problem don't you? Or is LiveCode capable somehow of communicating
> on multiple sockets simultaneously?
>
> Bob
>
>
> On Nov 23, 2010, at 6:15 AM, Andre Garzia wrote:
>
> > Fredrik,
> >
> > Instead of risking problems by having concurrent queries to a single
> SQLite
> > database, why don't you build a middleware?
> >
> > From your email, I understood that the problem is that you can't install
> a
> > server such as MySQL because the IT dept will be shouting. So why don't
> you
> > use LiveCode to build a little self contained server which talks to
> SQLite,
> > then all the clients would talk to this same server, this way, there's no
> > concurrent access since everything passes thru the server.
> >
> > If you're on LAN then it would be überquick to get the data around and
> you
> > would not have to face multi user access to a single file resource (this
> is
> > always troublesome).
> >
> > Andre
> > _______________________________________________
> > use-livecode mailing list
> > use-livecode at lists.runrev.com
> > Please visit this url to subscribe, unsubscribe and manage your
> subscription preferences:
> > http://lists.runrev.com/mailman/listinfo/use-livecode
>
>
> _______________________________________________
> use-livecode mailing list
> use-livecode at lists.runrev.com
> Please visit this url to subscribe, unsubscribe and manage your
> subscription preferences:
> http://lists.runrev.com/mailman/listinfo/use-livecode
>



-- 
http://www.andregarzia.com All We Do Is Code.



More information about the use-livecode mailing list