http://dev.mysql.com/doc/refman/5.0/en/control-flow-functions.html#function_if

On Fri, Jan 8, 2010 at 5:52 PM, machiel.richards <machiel.richa...@gmail.com
> wrote:

> Hi guys,
>
>
>
> Can you please assist me in rewriting this query in order to run this
> against a mysql database?
>
>
>
> It seems that the decode function does not exist in mysql.
>
>
>
> select
>
>   decode(nvl(receive_email, 'No'), 'Yes', 'Yes', 'No') email_corr,
>
>   count(*) tot
>
> from profiles
>
> where email is not null
>
> group by (decode(nvl(receive_email, 'No'), 'Yes', 'Yes', 'No'))
>
>
>
>
>
>
>
>


-- 
Best Regards,

Prabhat Kumar
MySQL DBA
Datavail-India Mumbai
Mobile     : 91-9987681929
www.datavail.com

My Blog: http://adminlinux.blogspot.com
My LinkedIn: http://www.linkedin.com/in/profileprabhat

Reply via email to