If you would like to purge all unauthorized users for your portal because there are hundreds of Unauthorized users that are waiting for approval, you can delete them in bulk through a SQL script.
Please note that since this process involves directly updating the database, it is highly recommended to create a backup first. The steps to bulk delete unauthorized users are as follows:
1. log in as a superuser and navigate to the SQL Console on the website using the steps in our KB article Running SQL Queries using the SQL Console.
2. [Optional] To list all the non-deleted and unauthorized users using the SQL console, please run the below query. This query does not make any changes to the database, it just lists user accounts.
select A.UserID, A.Username, A.FirstName, A.LastName, A.Email, B.Authorised, B.IsDeleted
Users A join UserPortals B
A.UserID = B.UserID
B.Authorised = 0 and B.IsDeleted = 0
3. Running the below update query will mark all unauthorized user accounts as deleted.
Authorised = 0 and IsDeleted = 0
4. Once the unauthorized user accounts are marked as deleted, you can then use the steps I shared earlier today to permanently remove (purge) these user accounts.