Contribute Media
A thank you to everyone who makes this possible: Read More

Some less obvious uses of SQLite


SQLite is arguably the most widely used database system if it's website is to be believed. From applications in aviation to the cellphone industry.

Yet another practical application that has been suggested by it's creator is that of an application file format. To quote the website: "SQLite does not compete with client/server databases. SQLite competes with fopen()."

In other words, instead of rolling out your own file format, why not use a file format that is accessible via a commonly known language (SQL)?

SQLite is included by default in a number of operating systems such as Blackberry 10 OS, Google Android, Net/Open/FreeBSD, Oracle Solaris 10, Apple OSX 10.4+ and Windows 10 amongst others. Programming languages with bindings for SQLite are C, C#, C++, Go, Java, Javascript, PHP, Python, Lisp and others. This means that SQLite can be used across a very wide range of the most popular devices and environments. Major operating systems support Sqlite out of the box, making it easy to port as well without needing to worry about cross-platform compatibility.

One example of how SQLite and Python could be of use is in incoming product information processing. We have various CSV or XML product feeds that provides locations to product images via a cabal of bash scripts. The idea would be to convert the information into a common format, ie SQLite rows and tables and allow jobs to process these rows, instead of creating bespoke scripts to act directly on the feed files themselves.

The obvious advantage of using SQLite and Python for this task is that it keeps overhead down and has the advantage of better structure, exception handling, portability and extensibility


Improve this page