Choose your database:
AnySQL
MySQL
MS SQL Server
PostgreSQL
SQLite
Firebird
Oracle
SQL Anywhere
DB2
MaxDB

Subscribe to our news:
Partners
Testimonials
J Canepa: "There is a lot of software out there for managing PostgreSQL. Yours is simply the best! Great product".
Jad Cooper: "Your program is the best. I have only few hours but now I make very great data for my meeting".

More

Add your opinion

PostgreSQL Maestro online Help

Prev Return to chapter overview Next

NOT NULL constraints

A NOT NULL constraint is the most generic constraint type. It allows you to specify that the value in a certain column must satisfy a Boolean (truth-value) expression.

 

The NOT NULL Constraint editor allows you to add a new check constraint or edit an existing one. This dialog can be invoked from Table Editor, or via the popup menu of the corresponding nodes of the explorer tree.

 

 

NOT NULL constraints are created within NOT NULL Constraint Properties dialog window. In order to open the dialog you should:

 

open the table in Table Editor and the NOT NULL Constraints tab there;
press the Insert key or select the Add New NOT NULL Constraint... item from the popup menu (alternatively, you may use the corresponding link of the Navigation Bar).

 

 

 

NOT NULL constraints are edited within the NOT NULL constraints Properties dialog window. In order to open the dialog you should:

 

open the table in Table Editor and the NOT NULL Constraints tab there;
press the Enter key or select the Edit NOT NULL Constraints item from the popup menu (alternatively, you may use the corresponding link of the Navigation Bar).

       

You can change the name of the NOT NULL constraint using the Rename NOT NULL Constraint dialog. To open the dialog you should:

 

open the table in Table Editor and the NOT NULL Constraints tab there;
select the NOT NULL constraint to rename;
select the Rename NOT NULL Constraint item from the popup menu (alternatively, you may use the corresponding link of the Navigation Bar).

 

 

 

To drop the NOT NULL constraint:

 

open the table in Table Editor and the NOT NULL Constraints tab there;
press the Delete key or select the Drop NOT NULL Constraint item from the popup menu (alternatively, you may use the corresponding link of the Navigation Bar)

 

and confirm dropping in the dialog window.

 

 


 

Name

The name of the NOT NULL constraint.

 

Comment

The box allows you to set optional text describing the NOT NULL constraint.

 

Column

Select the table column this constraint to be applied.

 

Not validated

Turn this option ON to skip a scan of the table to verify that all existing rows in the table satisfy the constraint. In this case the constraint will be applied against new inserts or updates. The database will not assume that the constraint holds for all rows in the table, until it will be validated manually via popup menu of the NOT NULL constraints tab in the Table Editor. Icons for not validated constraints are marked with a red exclamation mark in GUI.



Prev Return to chapter overview Next