When i execute sql commands, i.e. create table inside java code, does it matter if i write :
db.execSQL("create table mytable ("
+ "scores int, "
+ ");");
}
Or this:
db.execSQL("create table mytable ("
+ "scores INTEGER,"
+ ");");
}
Or it is both same thing, just different syntax?
Sqlite3 documentation says if you use INT then the column has "resulting affinity" : INTEGER. Typenames INT, INTEGER, TINYINT, SMALLINT, MEDIUMINT, BIGINT, UNSIGNED BIG INT, INT2, INT8 from the CREATE TABLE statement or CAST expression: give INTEGER affinity for the column.
For Sqlite2 see this answer
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With