---
title: "Update or Insert Group"
---
# Update or Insert Group
>
>
You can update a row or insert a new row into the database when a key pair combination does not exist. This eliminates the need to have a database that has every possible option considered in its original design. Because of the **insert row when not present** setting, the group will insert a new record whenever the designated ID doesn't exist. Afterwards, it will update the rows in the table that are associated with the key/value references as shown in this example.
## Update or Insert a New Row into the Database
1. In the Project Browser, right-click on Transaction Groups and select **New Standard Group**.

2. Give the group a name and click **Create Group**.
3. Drag a group of tags into the groups **Basic OPC/Group Items** section.

4. Change one of the tags to be read-only by selecting **Read Only** from the tag's **Target Name** column.

5. In the group's **Action** tab, in the **Table action** area, select the **update/select** radio button and the **key/value pairs** radio button.

6. Click the **Add** () icon.
1. For the **Column**, select the database table ID column.
2. For the **Value** column, select the read-only tag.
3. Select **Insert row when not present** check box at the bottom of the **Table action** area.
7. Select the group, and click **Enabled**.
8. Save the project to start the group.