16 lines
633 B
MySQL
16 lines
633 B
MySQL
|
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, LastName, Email, ProfilePictureUrl, CreationDate, SecurityStamp, StatusId)
|
||
|
select '***REMOVED***' as UserName,
|
||
|
'***REMOVED***' as [Password],
|
||
|
***REMOVED*** as FirstName,
|
||
|
***REMOVED*** as LastName,
|
||
|
'***REMOVED******REMOVED***' as Email,
|
||
|
***REMOVED*** as ProfilePictureUrl,
|
||
|
getdate() as CreationDate,
|
||
|
cast(newid() as varchar(100)) as SecurityStamp,
|
||
|
@activeStatusId as StatusId
|
||
|
end
|