Some food for thought when working with NULL values.


select count(*)
from ps_dwsa_prog_dtl
COUNT(*)
----------
657662
1 row selected

select count(*)
from ps_dwsa_prog_dtl
where acad_sub_plan ='13'
COUNT(*)
----------
13
1 row selected

select count(*)
from ps_dwsa_prog_dtl
where acad_sub_plan <>‘13′
COUNT(*)
———-
148559
1 row selected

select count(*)
from ps_dwsa_prog_dtl
where acad_sub_plan is null
COUNT(*)
———-
509090
1 row selected