Answer the question
In order to leave comments, you need to log in
How to implement counting the number of elements with a specific SQL value?
I have the following table
. For each element, I need to display its count with the active status.
I tried to implement this using this query: SELECT name, COUNT(status='active') FROM docs GROUP BY name
but in this case all fields are considered.
Please tell me what is wrong and how to fix it
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question