sqlite administrator: querying boolean fields
Posted: 24.02.2009, 17:17
I've set up a table called Photos. In that table there are two boolean fields, Public and Active. No rocket science here. However, when I query on those fields I get no records back (within SQLite admin).
-- 4 rows, with Active and Public = true for all
SELECT pics$.Caption, pics$.Id, pics$.Path, pics$.Public, pics$.Active
FROM main.Pictures pics$
-- no rows
SELECT pics$.Caption, pics$.Id, pics$.Path, pics$.Public, pics$.Active
FROM main.Pictures pics$
where pics$.Active = 1
-- also no rows
SELECT pics$.Caption, pics$.Id, pics$.Path, pics$.Public, pics$.Active
FROM main.Pictures pics$
where pics$.Active = '1'
Is this a bug in the SQLite Admin tool? I'm going to try a different tool and see... But it could be my query that's the problem. Also, the dollar signs are weird, they're generated by DbLinq tho.
-- 4 rows, with Active and Public = true for all
SELECT pics$.Caption, pics$.Id, pics$.Path, pics$.Public, pics$.Active
FROM main.Pictures pics$
-- no rows
SELECT pics$.Caption, pics$.Id, pics$.Path, pics$.Public, pics$.Active
FROM main.Pictures pics$
where pics$.Active = 1
-- also no rows
SELECT pics$.Caption, pics$.Id, pics$.Path, pics$.Public, pics$.Active
FROM main.Pictures pics$
where pics$.Active = '1'
Is this a bug in the SQLite Admin tool? I'm going to try a different tool and see... But it could be my query that's the problem. Also, the dollar signs are weird, they're generated by DbLinq tho.