USP_IDMAPPER_DISCOUNTHISTORY

Parameters

Parameter Parameter Type Mode Description
@SOURCEID uniqueidentifier IN
@TARGETID uniqueidentifier INOUT

Definition

Copy


CREATE procedure dbo.USP_IDMAPPER_DISCOUNTHISTORY
(
    @SOURCEID uniqueidentifier,
    @TARGETID uniqueidentifier output
)
as
    set nocount on;

    select @TARGETID = isnull(SUPERSEDEDBYID, @SOURCEID)
    from dbo.DISCOUNT
    where ID = @SOURCEID;

    return 0;