2.2. Version specific fields
One of the main pgModeler features is the generation of SQL code from a database model, but depending on the kind of objects, the user must pay attention to the attributes filled in these objects. Since a DDL command for a specific object can vary from version to version of PostgreSQL, pgModeler tries to handle this situation through its dynamic code generation mechanism that takes into account the version of the target database, detected during export.
Throughout pgModeler's forms, it's common to find fields whose labels are highlighted in bold and underlined, like the options marked in the images below, where the tooltip of each of them is shown. A highlighted field is available only in some PostgreSQL versions. The versions are informed in the field's tooltip (for example, PostgreSQL<= 11.0), so think twice when assigning values to these fields to avoid warnings or even error messages coming from a PostgreSQL server. If you need to use them, you must export the model to a server whose version matches the one informed in the field's tooltip.
1
| Table | ||
|---|---|---|
| # | Field | Description |
| 1 | With OID | Creates the table with OIDs, a system column that identifies each row. Available on PostgreSQL 11 or earlier. |
1
| Column | ||
|---|---|---|
| # | Field | Description |
| 1 | Generated | Makes the column a generated one, whose value is computed from other columns. Available on PostgreSQL 12 or later. |
12
| Constraint | ||
|---|---|---|
| # | Field | Description |
| 1 | Nulls not distinct | Makes the unique constraint consider null values as equal ( |
| 2 | Temporal key | Creates a temporal key ( |