USP_DATAFORMTEMPLATE_EDITLOAD_ACADEMICCATALOGSUBDEPARTMENT
The load procedure used by the edit dataform template "Academic Catalog Sub Department Edit 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. |
| @TSLONG | bigint | INOUT | Output parameter indicating the TSLONG value of the record being edited. This is used to manage multi-user concurrency issues when multiple users access the same record. |
| @PARENT | nvarchar(150) | INOUT | Parent |
| @USERID | nvarchar(50) | INOUT | ID |
| @NAME | nvarchar(150) | INOUT | Name |
| @DATEFROM | UDT_FUZZYDATE | INOUT | Date from |
| @MAKEHISTORICAL | bit | INOUT | Move to catalog history |
| @TYPE_CODE | tinyint | INOUT | Type code |
| @HISTORY | xml | INOUT | Catalog history |
| @ISHISTORICAL | bit | INOUT | Historical |
Definition
Copy
CREATE procedure dbo.USP_DATAFORMTEMPLATE_EDITLOAD_ACADEMICCATALOGSUBDEPARTMENT
(
@ID uniqueidentifier,
@DATALOADED bit = 0 output,
@TSLONG bigint = 0 output,
@PARENT nvarchar(150) = null output,
@USERID nvarchar(50) = null output,
@NAME nvarchar(150) = null output,
@DATEFROM dbo.UDT_FUZZYDATE = null output,
@MAKEHISTORICAL bit = null output,
@TYPE_CODE tinyint = null output,
@HISTORY xml = null output,
@ISHISTORICAL bit = null output
)
as
set nocount on;
set @DATALOADED = 0;
set @TSLONG = 0;
select
@DATALOADED = 1,
@TSLONG = TSLONG,
@USERID = USERID,
@NAME = NAME,
@DATEFROM = DATEFROM,
@PARENT = dbo.UFN_ACADEMICCATALOG_GETPARENT(6, ID),
@TYPE_CODE = 6, --Department
@ISHISTORICAL = ISHISTORICAL
from
dbo.ACADEMICCATALOGSUBDEPARTMENT
where
ID = @ID;
set @HISTORY = dbo.UFN_ACADEMICCATALOG_GETHISTORY_TOITEMLISTXML(6, @ID)
return 0;