Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Is it possible to have a remote sqlite database

Tags:

sqlite

ios

iphone

Can you store an sqlite database remotely on a server? I am building an iphone app and all the tutorials seem to store the sqlite database on the iphone itself...

like image 480
user559142 Avatar asked Jun 27 '11 14:06

user559142


People also ask

Can you access SQLite remotely?

SQLite isn't a network database, so it doesn't have any network connection ability built into it. You would need to either: Make the SQLite DB available on a network-accessible shared drive OR. Write/find an existing network server/web service for it.

Can you host a SQLite database online?

1) SQLite is not a traditional SQL Database, no server is necessary there is only a file. 3) You can upload the sqlite database to a webserver as a regular file, but with only backup intents this is plausible.

Can SQLite be hosted on a server?

You can run SQLite on a server, but it is better to use MySQL, PostgreSQL or the like.

Can SQLite handle multiple users?

Yes SQLite can support multiple users at once. It does however lock the whole database when writing, so if you have lots of concurrent writes it is not the database you want (usually the time the database is locked is a few milliseconds - so for most uses this does not matter).


1 Answers

That is not advisable, as you will quickly run into concurrency problems. I would use a traditional RDMS such as MySQL or PostegreSQL in such a case.

SQLite has a useful page explaining when to use it. It says:

If you have many client programs accessing a common database over a network, you should consider using a client/server database engine instead of SQLite.

like image 67
Matthew Flaschen Avatar answered Oct 17 '22 00:10

Matthew Flaschen