web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / How to implement valid...
Power Apps
Unanswered

How to implement validation rules?

(0) ShareShare
ReportReport
Posted on by

Hi,

 

we are currently looking for a possibility to replace an SQL Server with Dataverse. To hit the goal we have to make sure that different types of data validation is possible. Some points I was able to set up, but for one request I don't find a solution. I have a table with 8 colmuns. The distinct value of the first three columns must be unique in the whole table. For example:

 

Colmun1Column2Column3 
123ABC1A2BTrue
123BCD1A2BTrue
345ABC2B3CTrue
567HIJ1A2BTrue
123ABC1A2BFalse

 

In every column it is allowed to have the same value in mulitple rows. But the combination of the values in the first three rows have to be unique. If the value isn't unique you are not allowed to save the entry. Is there any way the set up a validation rule like this in dataverse? 

I have the same question (0)
  • SimnaJ Profile Picture
    205 on at

    Yes, it is possible to set up a validation rule in Dataverse to ensure that the combination of values in the first three columns of your table is unique. Here's how you can do it:

    • Navigate to the table in question and click on "Business rules" in the command bar at the top of the page.
    • Click "New" to create a new business rule.
    • In the "Details" section, give your rule a name and description.
    • In the "Scope" section, select the table you want to apply the rule to.
    • In the "Condition" section, click "Add step" and select "Condition".
    • Set the condition to check if the combination of values in the first three columns of the current record is unique. You can do this by using the "Lookup" function to search for existing records with the same values. Here's an example formula:
      Lookup(Table, Column1 = ThisRecord.Column1 && Column2 = ThisRecord.Column2 && Column3 = ThisRecord.Column3)
    • In the "Actions" section, click "Add step" and select "Stop processing rules". This will prevent the record from being saved if the condition is not met.
    • Save and activate your rule.

    With this business rule in place, any attempt to save a record with the same combination of values in the first three columns as an existing record will trigger a validation error, preventing the record from being saved.
    If you found this post helpful, please give it a thumbs up and consider marking it as a solution so others can benefit from it as well. Thank you!

  • Community Power Platform Member Profile Picture
    Microsoft Employee on at

    @SimnaJ thanks for the quick reply.

     

    I'm fairly new to Dataverse and business rules. I can follow until the condition step. How do I have to set up the condition so that I can use a formula like this? I can only choose entity as source and then I have to choose a field.  

    And where can I find the "Stop processing rules"?

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Users!

Kudos to our 2025 Community Spotlight Honorees

Congratulations to our 2025 community superstars!

Congratulations to the March Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
11manish Profile Picture

11manish 530

#2
WarrenBelz Profile Picture

WarrenBelz 459 Most Valuable Professional

#3
Haque Profile Picture

Haque 314

Last 30 days Overall leaderboard