alter proc <pre lang="sql">alter proc mobile_select
(@maingroupid int)
as
begin
select mobile
from tbl_mobile, tbl_maingroup, tbl_subgroup
where
tbl_maingroup.maingroupId=@maingroupid and
tbl_maingroup.maingroupId=tbl_subgroup.maingroupId and
tbl_mobile.subgroupId=tbl_subgroup.subgroupId
end