Subject Re: [firebird-php] comparing column with constant value
Author Michal Žeravík
Thank you a lot, this is exactly what I need.
Should I index the column in CASE WHEN ?

Michal


Lutz Br�ckner wrote:

>>>I'd like to use this construction :
>>>SELECT userid, username, userid=3 isthis FROM users;
>>>
>>>Is it possible to get 1 in column isthis when userid=3 ?
>>>
>>>
>
>with Firebird 1.5 you can do
>
>SELECT userid,
> username,
> CASE WHEN (userid=3) THEN 1 ELSE NULL END AS isthis
> FROM users;
>
>Lutz
>
>



[Non-text portions of this message have been removed]