USP_DATAFORMTEMPLATE_EDITLOAD_DEFAULTWEALTHPOINTCREDENTIALS_2
The load procedure used by the edit dataform template "Default WealthPoint Credentials Edit Form 2"
Parameters
Parameter | Parameter Type | Mode | Description |
---|---|---|---|
@DATALOADED | bit | INOUT | Output parameter indicating whether or not data was actually loaded. |
@CURRENTAPPUSERID | uniqueidentifier | IN | Input parameter indicating the ID of the current user. |
@USERNAME | nvarchar(100) | INOUT | User name |
@PASSWORD | nvarchar(100) | INOUT | Password |
@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_DEFAULTWEALTHPOINTCREDENTIALS_2 (
@DATALOADED bit = 0 output,
@CURRENTAPPUSERID uniqueidentifier,
@USERNAME nvarchar(100) = null output,
@PASSWORD nvarchar(100) = null output,
@TSLONG bigint = 0 output
) as
set nocount on;
set @DATALOADED = 0;
set @TSLONG = 0;
exec dbo.USP_GET_KEY_ACCESS;
if exists(select 1 from dbo.WEALTHPOINTCREDENTIALS where ID=@CURRENTAPPUSERID)
select
@DATALOADED = 1,
@USERNAME = USERNAME,
@PASSWORD = convert(nvarchar(100), DecryptByKey(PASSWORD))
from
dbo.WEALTHPOINTCREDENTIALS
where
ID = @CURRENTAPPUSERID;
else begin
set @DATALOADED = 1
set @USERNAME = ''
set @PASSWORD = ''
end
close symmetric key sym_BBInfinity;
return 0;