Cannot insert row in column

Issue #389 new
Inseo Choi created an issue

CREATE TABLE "transactions" ( 'trans_id' INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, 'user_id' INTEGER NOT NULL, 'comp_id' INTEGER NOT NULL, 'shares' INTEGER NOT NULL, 'price' REAL NOT NULL, 'time' DATETIME NOT NULL);

I attached the error message and the code I typed in to create rows in the transactions table.

Comments (3)

  1. phpLiteAdmin repo owner

    You are trying to add a row (not column) to the table transactions? What values are you trying? In the column trans_id, you need to enter an integer value, everything else will fail. SQlite is not strictly typed, you can normally pass strings into INTEGER columns. But columns defined as INTEGER PRIMARY KEYwill become ROWID-columns and thus, you can only pass integers into them. All other columns of transactions are NOT NULL, so you need to enter some value and cannot leave any of them blank.

  2. Log in to comment