USP_DATAFORMTEMPLATE_EDITLOAD_GROUPWEALTHCAPACITY

The load procedure used by the edit dataform template "Group Wealth Capacity Edit Form"

Parameters

Parameter Parameter Type Mode Description
@ID uniqueidentifier IN The input ID parameter used to load the fields defined on the form.
@ESTIMATEDWEALTHID uniqueidentifier INOUT Estimated wealth
@ESTIMATEDWEALTHVALUE money INOUT Estimated wealth value
@MAJORGIVINGCAPACITYID uniqueidentifier INOUT Major giving capacity
@MAJORGIVINGCAPACITYVALUE money INOUT Major giving capacity value
@OVERALLRATINGCODEID uniqueidentifier INOUT Overall rating
@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.
@DATALOADED bit INOUT Output parameter indicating whether or not data was actually loaded.

Definition

Copy

                    CREATE procedure dbo.USP_DATAFORMTEMPLATE_EDITLOAD_GROUPWEALTHCAPACITY (
                        @ID uniqueidentifier,
                        @ESTIMATEDWEALTHID uniqueidentifier = null output,
                        @ESTIMATEDWEALTHVALUE money = null output,
                        @MAJORGIVINGCAPACITYID uniqueidentifier = null output,
                        @MAJORGIVINGCAPACITYVALUE money = null output,
                        @OVERALLRATINGCODEID uniqueidentifier = null output,
                        @TSLONG bigint = 0 output,
                        @DATALOADED bit = 0 output
                    ) as 
                        set nocount on;

                        select
                            @DATALOADED    = 1,
                            @TSLONG = WC.[TSLONG],
                            @ESTIMATEDWEALTHID = WC.[ESTIMATEDWEALTHID],
                            @ESTIMATEDWEALTHVALUE = WC.[ESTIMATEDWEALTHVALUE],
                            @OVERALLRATINGCODEID = WC.[OVERALLRATINGCODEID],
                            @MAJORGIVINGCAPACITYID = WC.[MAJORGIVINGCAPACITYID],
                            @MAJORGIVINGCAPACITYVALUE = WC.[MAJORGIVINGCAPACITYVALUE]
                        from
                            dbo.CONSTITUENT C
                        left join
                            dbo.WEALTHCAPACITY WC
                        on
                            C.ID = WC.ID
                        where
                            C.ID = @ID;