You need to sign in to do that
Don't have an account?
krish_
Global Function to check the Salesforce Username...
Hi to all,
I want to create user in my organisation through code using contact record values.
I use the User's Username as contact Email Field.
How do I check the Email id is not repeated in whole salesforce DB???
Is there any global functions are there???
Send me the sample code...
Thanks,
Krish.
I want to create user in my organisation through code using contact record values.
I use the User's Username as contact Email Field.
How do I check the Email id is not repeated in whole salesforce DB???
Is there any global functions are there???
Send me the sample code...
Thanks,
Krish.
Use SOQL in your code.
Lisr<User> users = [SELECT id, name FROM User WHERE username = :email];
The above SOQL query is retrived only for the my Organisation user's only.
I want to check the whole Salesforce user names..
How to write the SOQL query to check the user's username on salesforce DB???
Thanks,
Krish.
I believe you are going to have to try to create the user and then catch the exception in the event that the username already exists.
how i can populate roles from my organisation??
can you provide me code for it??
have u succeeded in querying the entire salesforce database?
Thanks,
geet.
Hi Everyone,
I've reached out to salesforce related to this issue and confirmed that there are no workaround to check where the username exist across different salesforce org the user has.
The only way is to contact salesforce support as part of the Salesforce security protocols.
Hope this helps.
Regards,
Gen