Reputation: 847
I have a SQLiteDatabase and I want to select the rows where one of the row's column is equal to a text. I know to do this with integer but I don't know how to do this with text. And I would like to have more options as WHERE theColumn is equal a or b or c.
Upvotes: 0
Views: 604
Reputation: 25873
SELECT * FROM table WHERE theColumn IN ('text1', 'text2', 'text3')
Try to avoid selecting whole rows when not necessary. Also keep in mind string comparisons take longer than integer ones.
Upvotes: 1