USP_DATAFORMTEMPLATE_EDITLOAD_CONSTITCOMMUNICATIONPREFERENCES

The load procedure used by the edit dataform template "Constituent Communication Preferences 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.
@NAME nvarchar(400) INOUT Name
@DONOTMAIL bit INOUT Mail
@DONOTEMAIL bit INOUT Email
@DONOTPHONE bit INOUT Phone
@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.

Definition

Copy


                    CREATE procedure dbo.USP_DATAFORMTEMPLATE_EDITLOAD_CONSTITCOMMUNICATIONPREFERENCES (
                        @ID uniqueidentifier,
                        @DATALOADED bit = 0 output,
                        @NAME nvarchar(400) = null output,
                        @DONOTMAIL bit = null output,
                        @DONOTEMAIL bit = null output,
                        @DONOTPHONE bit = null output,
                        @TSLONG bigint = 0 output
                    ) as
                        set nocount on;

                        select
                            @NAME = [NAME],
                            @DONOTMAIL = [DONOTMAIL],
                            @DONOTEMAIL = [DONOTEMAIL],
                            @DONOTPHONE = [DONOTPHONE],
                            @DATALOADED = 1
                        from
                            dbo.[CONSTITUENT]
                        where
                            [ID] = @ID;

                        return 0;