SQLite Forum

Select and count from 2 tables
Login
Note that these return the list of movie_id.  If you want the count, then simply count them:

```
select count(movie_id)
  from (
           select movie_id 
             from genremap, genres 
            where genremap.genre_id == genres.genre_id 
              and genre_name == 'Romance'
        INTERSECT
           select movie_id
             from genremap, genres
            where genremap.genre_id == genres.genre_id 
              and genre_name == 'Comedy'
       )
;
```

Sugary sprinkles can be used in the sub-select if you want.