USP_SIMPLELIST_CAMPAIGNHIERARCHYGOAL
Returns all of the campaign hierarchy goals for a given campaign.
Parameters
Parameter | Parameter Type | Mode | Description |
---|---|---|---|
@CAMPAIGNID | uniqueidentifier | IN | Campaign ID |
Definition
Copy
create procedure dbo.USP_SIMPLELIST_CAMPAIGNHIERARCHYGOAL (
@CAMPAIGNID uniqueidentifier = null
) as begin
declare @ROOTCAMPAIGNID uniqueidentifier
set @ROOTCAMPAIGNID = dbo.UFN_CAMPAIGN_GETROOTID(@CAMPAIGNID)
select
CAMPAIGNHIERARCHYGOAL.ID [VALUE],
CAMPAIGNHIERARCHYGOAL.NAME [LABEL]
from
dbo.CAMPAIGNHIERARCHYGOAL
where
CAMPAIGNHIERARCHYGOAL.CAMPAIGNID = @ROOTCAMPAIGNID
order by
CAMPAIGNHIERARCHYGOAL.NAME
end