It seems it did not show up in the list yet.

On June 22, 2018 at 16:46:48, Al Ex (a22...@gmail.com) wrote:

Is there a way to translate into a single DAL this sql query?


SELECT

SUM(IF(is_a = 'T',1,0)) as a,

SUM(IF(is_b = 'T',1,0)) as b

FROM table;


It counts the times is_a and is_b are True.
Fields 'is_a' and 'is_b’ have been declared in DAL as boolean.

Thank you

-- 
Resources:
- http://web2py.com
- http://web2py.com/book (Documentation)
- http://github.com/web2py/web2py (Source code)
- https://code.google.com/p/web2py/issues/list (Report Issues)
--- 
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 web2py+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to