function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
sirishasirisha 

how to deactivate the salesforce userlicense

Challenge Requirements
Create a new user with the following settings:
Profile: System Administrator
User License: Salesforce
Username: Must include guestadmin somewhere in it
The new user must be inactive

here its showing in setup>users 
i am only the system admin.and two userlicenses are used .
i cant find another user with salesforce userlicense.

help me how to deactivate the license 
Khan AnasKhan Anas (Salesforce Developers) 
Hi Sirisha,

Greetings to you!

You can check the total Licenses and used Licenses by looking into Company Information. Go to Setup -> Quick Find Search Box -> Company Information.

If you want the Users with a License Name of Salesforce than the following query can get them:
SELECT Id, Name, UserName FROM User WHERE Profile.UserLicense.Name = 'Salesforce'

1. Open "Developer Console" 
2. Click on the "Query Editor" tab at the bottom.
3. Copy the above query, paste it into the query box in the Developer Console and click "Execute".

I hope it helps you.

Kindly let me know if it helps you and close your query by marking it as solved so that it can help others in the future. It will help to keep this community clean.

Thanks and Regards,
Khan Anas
arsaniketsharmaarsaniketsharma
Try assigning another user licence to old user, and then assign salesforce user licence to new user.

OR

You can Freeze old user and then uncheck the active checkbox by editing the old user so that the user licence may get available for new user.

Hope this will be helpful.