Mojtaba Arvin:
I'm looking to write a Postgresql SELECT
in single query with WHERE
conditions :
SELECT 1 FROM foo_table
WHERE a = true
AND b = true
AND c = true
to do the following :
if (a and b and c) :
return 1
elif not ( a and b) :
return 2
elif not ( a and b and c) :
return 3
What is the best way?
Posted in S.E.F
via StackOverflow & StackExchange Atomic Web Robots
This Question have been answered
HERE