UFN_BATCH_GETORIGINATINGBATCHID
This function returns the originating batch ID for a given batch.
Return
Return Type |
---|
uniqueidentifier |
Parameters
Parameter | Parameter Type | Mode | Description |
---|---|---|---|
@BATCHID | uniqueidentifier | IN |
Definition
Copy
create function dbo.UFN_BATCH_GETORIGINATINGBATCHID
(
@BATCHID uniqueidentifier
)
returns uniqueidentifier as
begin
declare @RESULT as uniqueidentifier;
select
@RESULT = ORIGINATINGBATCHID
from
dbo.BATCH
where
ID = @BATCHID;
return @RESULT;
end