Solved How to learn SQLite with Qt?
-
Hi! I never learnt how to program with Databases but now I'm facing a problem in which I need to use database (Sqlite) but I don't have any idea of how should I use it so does anyone know any way in which I can learn how to use SQLITE databse with Qt ? Thanks in advance.
-
Hi! The wiki has one nice short example for that: https://wiki.qt.io/How_to_Store_and_Retrieve_Image_on_SQLite
-
@Wieland Ok, I think it's a good guide to start but I think I need something more extense.. I don't know if I'm explaining myself haha.
-
@cxam You can use sqlite just like any other SQL database. The Qt SQL module provides everything you'll need. Do you only need a guide to Qt SQL's API or do you also need an introduction to SQL itself?
-
@cxam
The key is SQL
http://www.w3schools.com/sql/default.asp
since you will be using it to create/modify and fetch the data.So IMHO, first thing to understand to some extend is SQL as it will make all things
more clear when using QSqlQuery.also
I highly recommend using
http://sqlitebrowser.org/
You can create/modify and test SQL directly with it. -
@Wieland @mrjj thank you both for helping me :)
-
A key is a single or combination of multiple fields in a table. Its is used to fetch or retrieve records/data-rows from data table according to the condition/requirement. Keys are also used to create relationship among different database tables or views.
[https://www.welookups.com/sql/default.html](https://www.welookups.com/sql/default.html
)