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

Is the number of columns in the database limited?



  • I am using QSqlTableModel
    I created a table in the database with 15 columns, now I want to add two more columns with it
    model_repo-> submitAll () returns true but no rows are added to the table, is there another way to add rows to the database? Is the number of columns in the database limited?



  • @Negar_mg
    The number of columns is not limited, or certainly nowhere near 15 columns.
    Whether any rows should be added to database via submitAll() depends on what you have previously done in the model to add rows?
    Adding new columns has nothing to do with submitAll().
    It seems very unclear whether you are adding columns or rows. You certainly should not be mixing the two! Adding new columns requires very different code from adding rows.



  • thank you :)


Log in to reply