Results 1 to 12 of 12

Thread: PyQT: The QSqlTableModel and how to wrap my head around it

Hybrid View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Join Date
    Mar 2020
    Location
    Graz, Austria
    Posts
    6
    Thanks
    1
    Qt products
    Platforms
    Windows

    Default Re: PyQT: The QSqlTableModel and how to wrap my head around it

    So I called the select() method at the very last... moved it on different positions, but I think the very problem seems to lay with loading the data in the model, since the row count keeps being 0!

  2. #2
    Join Date
    Jan 2008
    Location
    Alameda, CA, USA
    Posts
    5,233
    Thanks
    303
    Thanked 864 Times in 851 Posts
    Qt products
    Qt5
    Platforms
    Windows

    Default Re: PyQT: The QSqlTableModel and how to wrap my head around it

    Don't know how else to help. Maybe use "DB Browser for SQLite" to make sure that your empty select actually does something there and then try to map that to python. I thought you would at least have to issue some kind of real SELECT statement - "SELECT * from MyTable" to get a populated result.
    <=== The Great Pumpkin says ===>
    Please use CODE tags when posting source code so it is more readable. Click "Go Advanced" and then the "#" icon to insert the tags. Paste your code between them.

Similar Threads

  1. Build Qt-based app on Mac OS X, head file not found
    By leonardyu in forum Qt Programming
    Replies: 3
    Last Post: 25th February 2015, 14:01
  2. Replies: 2
    Last Post: 9th April 2013, 06:26
  3. How to display picture from raw data without head?
    By luochen601 in forum Qt Programming
    Replies: 1
    Last Post: 23rd July 2010, 10:30
  4. QNetworkAccessManager::head not working
    By jonks in forum Qt Programming
    Replies: 4
    Last Post: 21st October 2009, 22:23
  5. Replies: 1
    Last Post: 15th March 2009, 20:01

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.