Solution 2 answers your question quite nicely.
But here are additional SQL count examples which may make it clearer:
select COUNT(distinct regmaster.Code)
from regmaster
inner join journals_tbl j
on regmaster.Code = j.schlcode
where regmaster.isApprExam = 1
;
select COUNT(*) from first_tbl where isApprExam =1 and Code in (select schlcode from journals_tbl)
select COUNT(*)
from journals_tbl
where Code in (select schlcode from regmaster where isApprExam = 1)
;
select COUNT(*) from regmaster inner join journals_tbl j on regmaster.Code=j.schlcode where regmaster.isApprExam =1
Hopefully I got those right, and if so hope it helps you out in understanding.