On 11/24/2018 7:59 PM, Bart Smissaert wrote:
Thanks, was aware, but the SQL was indeed wrong as posted and should have brackets around the 2 or conditions.
In this case, as far as I can tell you should end up with diab_count equal to pat_count, since "emis_number in(select emis_number from diabetics)" is true for every row, guaranteed by the WHERE clause. -- Igor Tandetnik _______________________________________________ sqlite-users mailing list sqlite-users@mailinglists.sqlite.org http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users