USP_DATAFORMTEMPLATE_VIEW_FEEDALERTINSTANCEEXPRESSION
The load procedure used by the view dataform template "Custom Email Alert Instance 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 |
| @ALERTTYPEID | uniqueidentifier | INOUT | Alert type ID |
| @ALERTTYPENAME | nvarchar(100) | INOUT | Alert type name |
| @HASUSERS | bit | INOUT | Has users |
Definition
Copy
create procedure dbo.USP_DATAFORMTEMPLATE_VIEW_FEEDALERTINSTANCEEXPRESSION
(
@ID uniqueidentifier,
@DATALOADED bit = 0 output,
@NAME nvarchar(100) = null output,
@ALERTTYPEID uniqueidentifier = null output,
@ALERTTYPENAME nvarchar(100) = null output,
@HASUSERS bit = null output
)
as
set nocount on;
select
@DATALOADED = 1,
@ALERTTYPEID = ALERTTYPE.ID,
@ALERTTYPENAME = ALERTTYPE.NAME,
@NAME = FEEDALERTINSTANCE.NAME,
@HASUSERS = case when (select count(*) from dbo.APPUSERFEEDALERTINSTANCE where APPUSERFEEDALERTINSTANCE.FEEDALERTINSTANCEID = FEEDALERTINSTANCE.ID) > 0 then 1 else 0 end
from FEEDALERTINSTANCE
inner join dbo.ALERTTYPE on ALERTTYPE.ID = FEEDALERTINSTANCE.ALERTTYPEID
where FEEDALERTINSTANCE.ID = @ID