On 21 Apr 2014, at 12:43am, Stephen Chrzanowski wrote:
> Short of writing a server type application that listens for incoming
> communication, I'm not aware of anything of the sort. SQLite is an
> embedded library which compiles with your code, or, with references to
> external libraries installed on your local machine. SQLite doesn't behave
> well with ANY sort of networking capabilities.
>
> The best bet would be to have a server type of application that listens for
> inbound communications via TCP, and you build the server to deal with
> transactions.
>
> You can build an API based off PHP (Or pretty much any other language) on
> the server in which your windows app makes an HTTP request to your server,
> your server handles the SQL calls and then returns the results.
I agree with everything Stephen wrote, but I'll extend it with answers to the
next two questions you're going to ask.
A) Yes, you can write a PHP page (or a few different ones) which give you
SQLite access. You access them as normal web pages and they return results as
normal web pages. To save you lots of experimentation, if you do this I
recommend you pass your parameters in JSON format using POST rather than GET,
and return your results in JSON format. And use PHP's 'sqlite3' library rather
than PDO. Also, if your system is going to be used by anyone apart from you,
build in some security measures so the pages process requests only from the
programs you want them to obey. Writing something like this is not hard and
it's very satisfying when it works.
B) No, there is no standard solution to this that everyone uses and you can
download from a site somewhere. There are various reasons for this, but one
seems to be that although everyone describes their needs the same, once someone
comes up with a solution everyone immediately says "I can't possibly use this
unless ..." and adds something weird that only they'd want. So you're going to
have to write your own. Sorry.
Simon.
___
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users