Logo
For example "scheduled tasks"
Search
Info
Content
Category Navigation
  • 🎯  Solution Guides

  • Low Code Solutions

    Add "Tabs" to your app

    ID Target Link

    Use an address field to display a static street view thumbnail

    Turn your menu into a fixed menu

    Auto close mobile menu

    Display record information in a card

    How to add a back button to your app

    Add a collapsible accordion element to your app

    Code Snippets

    PHP Curl Create New Record

    PHP Get Records With Filters

    Google Scripts - Get record and create new records from connected table

    Save Tables and Fields into Spreadsheet

    Google Scripts - Export all records

    Webhook to save deleted records

    Send Messages to Slack

    Restrict Space and Force Uppercase in a Form

    Building Advanced Features

    Use Validation Rules to Ensure Unique Votes Per User

    Use Record Rules to Create an Audit Log

    Track current inventory with transactions

    Schedule Bookings and Prevent Double Bookings

    Create orders with multiple items and varying quantities

    2 Step Forms

    Unique Record Validation

    Restrict Editing Records to Record Owners

    Sum date/time field

    Duplicate Records

    Advanced App Customization

    How to embed a Tadabase page on another website

    Adding external fonts

    Custom Favicon

    Making apps mobile friendly

    Show date/time as a countdown

    Importing many images at once

    Adding QR Codes

    Adding charts to PDFs

    Customizing your app shortcut for mobile phones

    Animate parts of a page

    Design Customization

    Changing background colors

    Set background colors to the edge of a page

    Change the background of a column

    Add padding around a component

    Using an image as background for a page

    Adding a background image to a row, column, or component

  • Duplicate Connected Records

Categories
🎯 Solution Guides
Building Advanced Feat...
Unique Record Validation

Unique Record Validation

Depending on your requirements, checking fields for unique values can often be somewhat complex and can vary in complexity depending on your requirements. In this short article we'll look into 3 different unique record validation approaches available to you. 

 

Assigning unique record validation on the field level. 

To enable unique validation checks on the field level, open any field and set the value of "Unique" to "Yes"

e_iBGU6dIxSduzG-Qbv4JUqKR2YoqASMfA.png

This method will check for unique values no matter where the data is entered or edited including: Inline editing, Record Rules, Importing, and API (coming soon).  

 

Another method would be to add unique validation on the form using Validation Rules within the form. Adding validation on this level will only impact this particular form, not on the data table level. This approach allows you to customize the message displayed to the user when this validation check is triggered. 

 

To do this, open any form and go to the Validation Rules menu as seen in image below: 

nWbIFE9DjQ99OBKMJimJ8Sx_y0iyhrzvGg.png

 

Both of the above approaches will work to check if the value is unique throughout the entire table on a column level, not record level. Let's see the difference and how we can check for validation on a per record level as well.

When checking uniqueness on a column level, having multiple rules will run against each column and if any values are returned as not unique the error message will be displayed and the value will not be saved. 

 

For example: If we want to ensure that the "Job Name" AND "Job Description" fields are unique we can add a validation rule to check that both Name and Email are unique. The validation will check if both values exist anywhere in those columns, if both are found an error will be returned.
7vaiT9SKo1Ljv-QTOLVk_ByciXp4a_24Ew.png

 

With the above settings every record inserted will be checked for uniqueness in both fields and if they both exist an error will be shows as you can see below: 

qmFGqQ7Csbht5460KiV159nWgeiDLptTNw.png

 

Now suppose we want to only validate uniqueness within each record, not against all records in column For example: we don't mind having the same value twice, as long as its not within the same record, we can do that with a different setting by enabling the "Check Additional Fields" option and choosing which other fields/columns should be checked. 

h9n-7yqbQBNEwVvrQvgd5V8TbPG7eFCCwA.png

 

Even though both values exist, since they don't exist in the same record the value will be inserted without any errors:

L2DTQigFuxqtnUeioHCRXjDIJKABCOElTg.png

How did we do ?

Previous Article
2 Step Forms
Next Article
Restrict Editing Records to Record Owners
Back to top
API
100% Operational
Apps
100% Operational
Builder
100% Operational
Overall Status
100% Operational