Skip to content

Commit

Permalink
edittabledialg: table without rowid don't have to be integer pk columns
Browse files Browse the repository at this point in the history
  • Loading branch information
rp- committed Apr 10, 2015
1 parent 6231d3c commit cecf681
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions src/EditTableDialog.cpp
Expand Up @@ -546,13 +546,12 @@ void EditTableDialog::setWithoutRowid(bool without_rowid)
{
// Before setting the without rowid flag, first perform a check to see if the table meets all thr required criteria for without rowid tables
int pk = m_table.findPk();
if(pk == -1 || m_table.fields().at(pk)->isInteger() == false || m_table.fields().at(pk)->autoIncrement())
if(pk == -1 || m_table.fields().at(pk)->autoIncrement())
{
QMessageBox::information(this, QApplication::applicationName(),
tr("Please add a field which meets the following criteria before setting the without rowid flag:\n"
" - Primary key flag set\n"
" - Auto incremenct disabled\n"
" - Type INTEGER"));
" - Auto incremenct disabled"));
ui->checkWithoutRowid->setChecked(false);
return;
}
Expand Down

0 comments on commit cecf681

Please sign in to comment.