Skip to content
David Kittell
David Kittell

Application & System: Development / Integration / Orchestration

  • Services
    • Application Development
    • Online Application Integration
  • Code
  • Online Tools
  • Tech Support
David Kittell

Application & System: Development / Integration / Orchestration

DNN – Rename Admin User

Posted on May 4, 2015October 26, 2015 By David Kittell
SET NOCOUNT ON

DECLARE @OldUsername nvarchar(100),
   @NewUsername nvarchar(100)

SET @OldUsername = 'dkittell1'
SET @NewUsername = 'dkittell'

UPDATE dnn_Users SET [Username] = @NewUsername WHERE [Username] = @OldUsername;
UPDATE aspnet_Users SET [LoweredUserName] = @NewUsername WHERE [LoweredUserName] = @OldUsername;
UPDATE aspnet_Users SET [UserName] = @NewUsername WHERE [UserName] = @OldUsername;
UPDATE dnn_EventLog SET [LogUserName] = @NewUsername WHERE [LogUserName] = @OldUsername;
Originally Posted on May 4, 2015
Last Updated on October 26, 2015
All information on this site is shared with the intention to help. Before any source code or program is ran on a production (non-development) system it is suggested you test it and fully understand what it is doing not just what it appears it is doing. I accept no responsibility for any damage you may do with this code.

Related

Code DNN MSSQL MSSQL - DNN SQL

Post navigation

Previous post
Next post

Related Posts

Windows 7 – Disable Hibernate Mode

Posted on February 1, 2016

Disable Hibernate powercfg -h off Enable Hibernate powercfg -h on All information on this site is shared with the intention to help. Before any source code or program is ran on a production (non-development) system it is suggested you test it and fully understand what it is doing not just…

Read More

UNIX Bash – Create Date/Time File Name

Posted on August 25, 2016October 4, 2019

When you need to create a log file or some dated archive echo "This is a dated file $(date +%Y_%m_%d_%H.%M.%S)" > testfile_`date +%Y_%m_%d_%H.%M.%S`.txt The format can be modified slightly based on date formatting. Originally Posted on August 25, 2016Last Updated on October 4, 2019 All information on this site is…

Read More

MySQL Procedure Get WordPress Site Name

Posted on October 13, 2015October 13, 2015

If you manage many WordPress site databases it can get a bit crazy to know which site goes with what database but it gets more “fun” when you have a network site, below I attempt to help document some ways to help. This first example is a rather long process…

Read More

Code

Top Posts & Pages

  • PowerShell - Rename Pictures to Image Taken
  • Front Page
  • C# - Start/Stop/Restart Services
  • MacPorts / HomeBrew - Rip CD tracks from terminal
  • PowerShell - Show File Extensions

Recent Posts

  • Javascript – Digital Clock with Style
  • BASH – Web Ping Log
  • BASH – Picture / Video File Name Manipulation
  • Mac OSX Terminal – Create SSH Key
  • Bash – Rename Picture

Top Posts

  • PowerShell - Rename Pictures to Image Taken
  • C# - Start/Stop/Restart Services
  • MacPorts / HomeBrew - Rip CD tracks from terminal
  • PowerShell - Show File Extensions
  • Open On Screen Keyboard (OSK)
  • SQLite - Auto-Increment / Auto Generate GUID
©2025 David Kittell | WordPress Theme by SuperbThemes