cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
newmay
Helper V
Helper V

Unique username

Hi,

 

how can I achieve a unique username for portal users ? Same as for the ootb  site settings for email (Authentication/UserManager/UserValidator/RequireUniqueEmail)

 

Thanks!

5 REPLIES 5
ragavanrajan
Super User
Super User

Hi @newmay 

You can try creating a duplicate detection rule for the "Contact" table. 

 

ragavanrajan_0-1645486345253.png

official docs: https://docs.microsoft.com/en-us/power-platform/admin/set-up-duplicate-detection-rules-keep-data-cle...

 

Note: Remember to turn on the "Enable Duplicate detection" 

 


Hope it helps. 
------------

If you like this post, give it a Thumbs up. Where it solved your request, Mark it as a Solution to enable other users to find it.

@ragavanrajan but does this work for the portal? At best I want that a form throwns an error if the username is already taken (but within the power apps portal)

OliverRodrigues
Super User
Super User

I believe duplicated detection rules are ignored in the Portal @ragavanrajan, I could be wrong, might be worth trying it out

 

@newmay a few things here:

  1. Remember that local authentication is marked as Not Recommended by Microsoft: Overview of authentication in Power Apps portals - Power Apps | Microsoft Docs
  2. Ultimately you can use Alternate Keys in the dataverse level: Work with alternate keys (Microsoft Dataverse) - Power Apps | Microsoft Docs



If you like this post, give a Thumbs up. Where it solved your request, Mark it as a Solution to enable other users find it.

Power Apps Portals Super User


Oliver Rodrigues


 

Hi @newmay  & @OliverRodrigues 

 

Have tested the duplicate rules. Looks like it is working. Screenshot below for reference

 

ragavanrajan_0-1645587624107.png

 

@newmay  Please note as @OliverRodrigues  mentioned. Local Authentication is not supported. You may need to migrate it to Azure AD or Azure AD B2C. 

 

Cheers

 

Hope it helps. 
------------

If you like this post, give it a Thumbs up. Where it solved your request, Mark it as a Solution to enable other users to find it.

Hey @ragavanrajan I have a custom reg form with the default username field unfortunately the duplication rule does not work here and default username field cannot be used for an alternate key. So we would need to write a plugin I guess.

Helpful resources

Announcements
Power Platform Conf 2022 768x460.jpg

Join us for Microsoft Power Platform Conference

The first Microsoft-sponsored Power Platform Conference is coming in September. 100+ speakers, 150+ sessions, and what's new and next for Power Platform.

365 EduCon 768x460.png

Microsoft 365 EduCon

Join us for two optional days of workshops and a 3-day conference, you can choose from over 130 sessions in multiple tracks and 25 workshops.

Users online (4,813)