Results 1 to 5 of 5

Thread: QSqlTableModel Insertion Problem

Hybrid View

Previous Post Previous Post   Next Post Next Post
  1. #1
    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: QSqlTableModel Insertion Problem

    It could be failing because the data you are trying to write violates table constraints. For example, if a certain column must be not null, or a primary key field is not populated or a duplicate, a foreign key constraint is violated, or a value fails a check constraint.

  2. #2
    Join Date
    Dec 2011
    Posts
    18
    Thanks
    2
    Qt products
    Qt4
    Platforms
    Unix/X11

    Default Re: QSqlTableModel Insertion Problem

    Thanks a lot Chris! You rule!

    I hid some columns, and wasn't paying attention that I was submitting QStrings into TinyInt fields, Thanks again man

    EDIT: How can I label the thread asa [SOLVED] ?
    Last edited by Pluvius; 23rd December 2011 at 06:14.

Similar Threads

  1. problem with qsqltablemodel
    By ditsikts in forum Newbie
    Replies: 1
    Last Post: 30th October 2011, 22:34
  2. Replies: 4
    Last Post: 19th December 2010, 06:15
  3. Replies: 1
    Last Post: 16th June 2010, 20:19
  4. QSqlTableModel problem
    By waynew in forum Newbie
    Replies: 10
    Last Post: 8th January 2010, 00:48
  5. Multiple insertion using QSqlTableModel
    By munna in forum Newbie
    Replies: 3
    Last Post: 9th May 2006, 20:20

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.