Results 1 to 7 of 7

Thread: Performance of Using QSqlTableModel

Hybrid View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Join Date
    Sep 2009
    Location
    Wroclaw, Poland
    Posts
    1,394
    Thanked 342 Times in 324 Posts
    Qt products
    Qt4 Qt5
    Platforms
    MacOS X Unix/X11 Windows Android

    Default Re: Performance of Using QSqlTableModel

    What is "doSomething()" doing ?

  2. #2
    Join Date
    Jan 2014
    Posts
    20
    Thanks
    2
    Qt products
    Qt5
    Platforms
    Unix/X11 Windows

    Default Re: Performance of Using QSqlTableModel

    Quote Originally Posted by stampede View Post
    What is "doSomething()" doing ?
    let's say as follows,
    Qt Code:
    1. void doSomething()
    2. {
    3. i++;
    4. }
    To copy to clipboard, switch view to plain text mode 
    so this mean that the "while" loop need too much time to execute itself. Now i notice that tableA has a field which store blob, once i don't select this field, then the speed become fast! Why and how to deal with blob with QSqlTableModel?
    thanks!

  3. #3
    Join Date
    Sep 2009
    Location
    Wroclaw, Poland
    Posts
    1,394
    Thanked 342 Times in 324 Posts
    Qt products
    Qt4 Qt5
    Platforms
    MacOS X Unix/X11 Windows Android

    Default Re: Performance of Using QSqlTableModel

    BLOB is just a collection of bytes, it could be anything (for example image data), and it is up to the application to interpret it correctly. Looks like in your case it is quite large, so it affects the performance of your queries.

  4. #4
    Join Date
    Mar 2009
    Location
    Brisbane, Australia
    Posts
    7,729
    Thanks
    13
    Thanked 1,610 Times in 1,537 Posts
    Qt products
    Qt4 Qt5
    Platforms
    Unix/X11 Windows
    Wiki edits
    17

    Default Re: Performance of Using QSqlTableModel

    BLOBS are presented by Qt as a QVariant::ByteArray.

Similar Threads

  1. Replies: 8
    Last Post: 30th March 2011, 20:06
  2. QSqlTableModel and LIKE
    By JeanC in forum Qt Programming
    Replies: 2
    Last Post: 10th January 2008, 08:45
  3. QSqlTableModel Help pls
    By munna in forum Newbie
    Replies: 1
    Last Post: 7th March 2006, 19:40
  4. QSqlTableModel
    By raphaelf in forum Qt Programming
    Replies: 4
    Last Post: 4th March 2006, 12:35
  5. QSqlTableModel Help pls
    By munna in forum Newbie
    Replies: 1
    Last Post: 26th January 2006, 07:58

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
  •  
Qt is a trademark of The Qt Company.