Is it possible to pass a param to a query from within another query?
select Sum(hours) as total_hours from tot_hours where job_number = [@Job_Number] group by job_number;
select j.job_number, j.job_name, q.total_hours from job_master as j, Query1 as q;
How would I pass "job_number" to Query1 from within Query2?
Or am I completely off the mark?
group by job_number