I agree, it would be nice to have is_active as a real boolean although I don't know how difficult could be its implementation without breaking the backward compatibility. Furthermore, I've just checked my instance and is_active is saved as 'T' with postgres 9.1
Paolo On Friday, May 24, 2013 5:06:19 AM UTC+2, Massimo Di Pierro wrote: > > This is a backward compatibility issues. The fact that it inserts a 't' > instead of a 'T' is more of a concern to me. How was the query built? > > The source clearly says: > TRUE = 'T' > FALSE = 'F' > > On Thursday, 23 May 2013 16:21:18 UTC-5, Cliff Kachinske wrote: >> >> auth.signature appends a "boolean" field called is_active to a table. >> The default is True. >> >> Under the covers it's not really boolean, it's char(1). When you insert >> a record, is_active is set to "t". That's right, a lowercase t. >> >> Today I had the kind of problem where queries were missing records. It >> turns out that the DAL was emitting queries looking for 'T' in is_active. >> >> The queries were missing records because Postgres is case sensitive in >> char fields. >> >> I don't really understand why the dal adapters for Postgres transmogrify >> boolean fields to char(1) when Postgres supports boolean fields. The nice >> thing about that is Postgres boolean fields do not care about case. >> >> The easy fix for this problem is make sure that any fields you have >> defined as boolean in your models are also boolean in Postgres. >> > -- --- You received this message because you are subscribed to the Google Groups "web2py-users" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/groups/opt_out.

