allow to use _rowid_ as normal field
Opened this issue · 3 comments
zoff99 commented
is there a way to select "rowid" just like any other field of a table?
orma.selectFromTable()._rowid_Eq(myrowid)....
or update with rowid
orma.updateTablex()._rowid_Eq(myrowid)....
gfx commented
It's possible if you declare the field.
zoff99 commented
how can i declare rowid? this is already sqlite internal
gfx commented
Just declare @PrimaryKey long <your favorite name>
which is an alias to _rowid_
.
https://sqlite.org/autoinc.html
If a table contains a column of type INTEGER PRIMARY KEY, then that column becomes an alias for the ROWID.