我有 3 张桌子。查询条件:
Need to get number of Source_Id with status_id=1
Need to get number of Source_Id with status_id=3 except status_id=1
Need to get number of Source_Id with status_id=2 except status_id=1 and 3
表 1:状态
**Satus_Id Status**
1 Matching
2 Not Matching
3 Manual Matching
表 2:来源详情
**Source_Id Name Date**
1 Name1 21-01-2013
2 Name2 22-01-2013
3 Name3 22-01-2013
4 Name4 23-02-2013
表 3:来源
**Id Source_Id Satus_Id**
1 1 1
2 1 2
3 1 3
4 2 2
5 2 3
6 3 3
7 4 2
预期输出为
**Status Count**
Matching 1
Manual Matching 2
Not Matching 1