I have two tables Incident (id, date) Reminder (incident identifier, type) internal connection to event.id = reminder.incidentID
and I want to accept case.id only if it has more than 4 reminder.type = 15 what I think
SELECT incident.id
FROM incident
INNER JOIN reminder ON incident.id = reminder.incidentid
HAVING COUNT (reminder.remindertype = "something") >5
GROUP BY incident.incidentcode
In erroe I get
Line 6: Invalid syntax next to '='.
What can I do?
source
share