I'm interested in how I can write mysql query if I want to count some column from table (mysql database) where that column must be chosen within another query ?
like this
SELECT COUNT(OTHER_QUERY) FROM TABLE
I have column named port and want to count this column within another query like this (select port where port='GCP';
I'm trying to do this task but with no result (despite of helping)
I'm writing like so =>
SELECT COUNT(port) from data WHERE port = (select port from data where port='GCP')
So I want to count column port which are equal to GCP
please help with this task :)