Important: Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

Best way to create a simple local database [SOLVED]



  • Hello guys,

    I am rather new to Qt-Programming. I set up a little program for categorizing images. So far I am saving my informations within a QDomDocument and save/load it in a xml-file. So far everything works fine, but I need some more functions which I do not like to code by hand. I would like to have search/filter-functions and so on (e.g. like in SQL), but I do not want to install a local SQL-database, because I want it to be easy to download and use for other users.

    Is there any local-in-house-solution in Qt that I could use?
    Something that creates a database itself or at least within cpu-memory with the functionality to save and load to/from file?

    Thanks for tips!

    Charma



  • bq. SQLite is a software library that implements a self-contained, serverless, zero-configuration, transactional SQL database engine. SQLite is the most widely deployed SQL database engine in the world. The source code for SQLite is in the public domain.

    http://qt-project.org/doc/qt-4.8/sql-driver.html#qsqlite



  • Wow, thanks for the fast reply!

    That's exactly what I was looking for.

    Again, Thanks a lot!



  • to facilitate the creation and use of the bank sqlite, the use "SQlite Manager ":www.sqlitemanager.org , or the Firefox extension "SQlite Firefox Add-on ":https://addons.mozilla.org/pt-BR/firefox/addon/sqlite-manager/ .



  • Yes, I would "vote" for SQLite as well! ;-)



  • Thanks guys, I already managed to create a DB with Qt. I am using the sql-functionality of Qt itself. I did not download SQLite seperately.
    Works fine and I could already create tables in the database.


Log in to reply