USP_DATAFORMTEMPLATE_VIEW_NAMINGOPPORTUNITYPAGEEXPRESSION
The load procedure used by the view dataform template "Naming Opportunity Page Expression View Form"
Parameters
| Parameter | Parameter Type | Mode | Description |
|---|---|---|---|
| @ID | uniqueidentifier | IN | The input ID parameter used to load the fields defined on the form. |
| @DATALOADED | bit | INOUT | Output parameter indicating whether or not data was actually loaded. |
| @NAME | nvarchar(100) | INOUT | NAME |
| @ISACTIVE | bit | INOUT | ISACTIVE |
| @NUMBEROFRECOGNITIONS | int | INOUT | NUMBEROFRECOGNITIONS |
Definition
Copy
create procedure dbo.USP_DATAFORMTEMPLATE_VIEW_NAMINGOPPORTUNITYPAGEEXPRESSION
(
@ID uniqueidentifier,
@DATALOADED bit = 0 output,
@NAME nvarchar(100) = null output,
@ISACTIVE bit = null output,
@NUMBEROFRECOGNITIONS int = null output
)
as
begin
set nocount on;
set @DATALOADED = 0;
select top (1)
@DATALOADED = 1,
@NAME = NAMINGOPPORTUNITY.NAME,
@ISACTIVE = NAMINGOPPORTUNITY.ISACTIVE,
@NUMBEROFRECOGNITIONS = (select count(ID) from dbo.NAMINGOPPORTUNITYRECOGNITION where NAMINGOPPORTUNITYID = @ID)
from
dbo.NAMINGOPPORTUNITY
where
NAMINGOPPORTUNITY.ID = @ID
return 0;
end