Catch 1select count(SongId) from chartsquery RowsCount=0Catch 1Bselect count(SongId) from chartsquery where (genre='All Genres') RowsCount=0