Basically, I'm trying to get data from an SQL based on two different groups, t.type
has to equal single
and t.status
has to equal 1
but as for t.org
I want to it get both DUAL
and RA
, here's what I attempted to no avail.
SELECT
COUNT( p.tID )
FROM
ticket AS t
INNER JOIN
people AS p ON t.ID = p.tID
WHERE
t.type = 'single' AND t.status='1' AND t.org = 'RA' OR t.org = 'DUAL'
I'm pretty sure theirs a way to get this query working, just not in my head
See Question&Answers more detail:os