On 8 Sep 2016, at 11:07am, Dave Blake <davebl...@kodi.tv> wrote: > Looking for the best way to query a table with an integer column by value > of the lower 16 bits of the data in that column. Does SQLite support > bitwise logic?
Yes. You can use the following & | ~ << >> AND OR NOT SHIFTLEFT SHIFTRIGHT However it is far faster to search for integer values. So if your table has lots of rows and/or you do lots of queries like this, you should consider keeping a copy of the lower 16 bits as another integer column. Simon. _______________________________________________ sqlite-users mailing list sqlite-users@mailinglists.sqlite.org http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users