Home  >  Article  >  Topics  >  How to set the verification rule attribute in Access cannot be empty

How to set the verification rule attribute in Access cannot be empty

下次还敢
下次还敢Original
2024-04-10 14:12:061384browse

How to set the validation rule property in Access so that it cannot be null? Select the field, right-click and select Properties. In the Validation Rules tab, enter the validation rule: Is not Null. In Validation message, enter the error message you want to display. Click OK to save changes. Attempt to enter a null value and a verification message will be displayed.

How to set the verification rule attribute in Access cannot be empty

How to set the validation rule property in Access and cannot be empty

Step 1: Select the Set fields for validation rules

In the Access table design view, select the fields for which you want to set validation rules.

Step 2: Open the Field Properties dialog box

  • Right-click the field and select Properties.
  • Alternatively, on the Fields tab, in the View group, click Property Table.

Step 3: Set Validation Rules

On the Validation Rules tab of the Field Properties dialog box, enter the following validation rules:

<code>Is not Null</code>

Step 4: Set Validation Message

In the Validation Message field, enter the message you want to display when a null value is entered. For example:

<code>字段不可为空。</code>

Step 5: Click OK

Click OK to save changes and close the Field Properties dialog box.

Step 6: Test the validation rules

Attempt to enter NULL values ​​in the table for the affected fields. If you enter a null value, you will see the validation message you set.

The above is the detailed content of How to set the verification rule attribute in Access cannot be empty. For more information, please follow other related articles on the PHP Chinese website!

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn