13 lines
492 B
Transact-SQL
13 lines
492 B
Transact-SQL
if not exists (select top 1 1 from AppUser where UserName = '***REMOVED***')
|
|
begin
|
|
declare @activeStatusId int
|
|
select @activeStatusId = StatusId from UserStatus where StatusCode = 'ACTIVE'
|
|
|
|
insert into AppUser(UserName, [Password], FirstName, CreationDate, SecurityStamp, StatusId)
|
|
select '***REMOVED***' as UserName,
|
|
'***REMOVED***' as [Password],
|
|
***REMOVED*** as FirstName,
|
|
getdate() as CreationDate,
|
|
cast(newid() as varchar(100)) as SecurityStamp,
|
|
@activeStatusId as StatusId
|
|
end |