Define alternate keys using Power Apps portal

Note

Effective November 2020:

  • Common Data Service has been renamed to Microsoft Dataverse. Learn more
  • Some terminology in Microsoft Dataverse has been updated. For example, entity is now table and field is now column. Learn more

This article will be updated soon to reflect the latest terminology.

Power Apps provides an easy way to view and create table alternate keys with the Microsoft Dataverse. For more information about alternate keys, see Define alternate keys to reference rows.

Power Apps enables configuring the most common options, but certain options can only be set using solution explorer. More information: Define alternate keys using solution explorer

Important

If the data within a column that is used in an alternate key will contain one of the following characters /,<,>,*,%,&,:,\\,? then GET or PATCH actions will not work. If you only need uniqueness then this approach will work, but if you need to use these keys as part of data integration then it is best to create the key on columns that won't have data with those characters.

View alternate keys

  1. From the Power Apps portal, select Data > Tables and select the table that you want to view.

  2. Select Keys to view a list of any alternate keys that are defined.

    View alternate keys

Create an alternate key

  1. While viewing alternate keys, select Add key.

  2. Use the panel to set a Display name and choose the columns to use to create the alternate key.

    The Name column will be populated based on the display name.

    Example Alternate Key Definition

  3. Select Done to close the panel.

  4. Select Save table to create the alternate key.

Note

The alternate key will not be immediately available. A system job is initiated when you save the table to create database indexes to support the alternate key.

Delete an alternate key

While viewing alternate keys, select the key you want to delete and choose Delete Key from the command bar.

See also

Developer Documentation: Work with alternate keys

Note

Can you tell us about your documentation language preferences? Take a short survey.

The survey will take about seven minutes. No personal data is collected (privacy statement).