sqlite get ROWID

Sqlite

Sqlite Problem Overview


consider this simple table(tbl1):

A|first letter
B|second letter
C|third letter

first column is letter and second column is desc

I can do this query without any problem:

select * from tbl1 where letter='B'      -->>second letter

My question is: how I can get(retrieve) the ROWID of the result row?

Sqlite Solutions


Solution 1 - Sqlite

SELECT rowid, * FROM tbl1 WHERE letter = 'B'

Attributions

All content for this solution is sourced from the original question on Stackoverflow.

The content on this page is licensed under the Attribution-ShareAlike 4.0 International (CC BY-SA 4.0) license.

Content TypeOriginal AuthorOriginal Content on Stackoverflow
Questionayyob khademiView Question on Stackoverflow
Solution 1 - SqliteCL.View Answer on Stackoverflow