Skip to content

Commit 6464567

Browse files
authored
Field domain documentation (#10534)
2 parents ab0572f + a5c4172 commit 6464567

File tree

2 files changed

+64
-7
lines changed

2 files changed

+64
-7
lines changed

docs/user_manual/introduction/browser.rst

Lines changed: 6 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -316,6 +316,8 @@ each level of the dataset tree.
316316
| :menuselection:`New Field Domain --> | | | | | | |
317317
| New Glob Domain` | |checkbox| | | | | | |
318318
+--------------------------------------------+--------------+--------------+------------+------------+---------------+------------+
319+
| :guilabel:`New Relationship...` | |checkbox| | | | | | |
320+
+--------------------------------------------+--------------+--------------+------------+------------+---------------+------------+
319321
| :guilabel:`Delete <database_name>` | |checkbox| | |checkbox| | | | | |
320322
+--------------------------------------------+--------------+--------------+------------+------------+---------------+------------+
321323
| :guilabel:`Compact Database (VACUUM)` | |checkbox| | | | | | |
@@ -428,13 +430,6 @@ each level of the dataset tree.
428430
such as ESRI File Geodatabase, FlatGeobuf, GeoParquet, NetCDF, ... when compatible.
429431
.. [2] For PostgreSQL connections: only supported with ALTER TABLE privilege.
430432
431-
.. note::
432-
433-
When loading vector layers into QGIS, fields with |sourceFields| :guilabel:`Field Domains`
434-
(such as those defined in a GeoPackage or ESRI File Geodatabase) are automatically
435-
detected. These domains are database-level constraints, meaning they are enforced
436-
by the database itself and apply across different applications, not just QGIS.
437-
438433
Importing vector layers into databases using Browser panel
439434
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
440435

@@ -698,6 +693,10 @@ Supported file types
698693
:width: 1.5em
699694
.. |stac| image:: /static/common/mIconStac.png
700695
:width: 1.5em
696+
.. |symbologyAdd| image:: /static/common/symbologyAdd.png
697+
:width: 1.5em
698+
.. |symbologyRemove| image:: /static/common/symbologyRemove.png
699+
:width: 1.5em
701700
.. |tiledSceneLayer| image:: /static/common/mIconTiledSceneLayer.png
702701
:width: 1.5em
703702
.. |unchecked| image:: /static/common/unchecked.png

docs/user_manual/managing_data_source/supported_data.rst

Lines changed: 58 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -651,6 +651,58 @@ selecting the columns in the :guilabel:`Feature id` column. For best
651651
performance, the :guilabel:`Feature id` value should be a single ``INTEGER``
652652
column.
653653

654+
655+
.. index:: Field domain
656+
.. _field_domain:
657+
658+
Field domain
659+
-------------
660+
661+
Field domains are rules that define acceptable values for a field in a database table.
662+
This is applicable when working with data sources that support field domains,
663+
such as GeoPackage and ESRI File Geodatabase.
664+
Field domains can be managed from the contextual menu of a field in the :guilabel:`Browser` panel.
665+
The following types are available:
666+
667+
* :guilabel:`New Range Domain...`: creates a new domain to restrict field values
668+
to a specified numeric range.
669+
* :guilabel:`New Coded Values Domain...`: creates a new domain to
670+
restrict field values to a predefined list of acceptable values.
671+
* :guilabel:`New Glob Domain...`: creates a new domain to restrict field values
672+
to matching a regular expression pattern.
673+
674+
When creating a field domain, following options are provided in the dialog:
675+
676+
* :guilabel:`Name`: set the name of the new field domain.
677+
* :guilabel:`Description`: provide a description for the new field domain.
678+
* :guilabel:`Field type`: select the data type of the field domain
679+
(e.g., Boolean, Text, Integer, Decimal).
680+
* Additional :ref:`Policies <policies>`, only available for ESRI File Geodatabase format:
681+
682+
* :guilabel:`Split policy`
683+
* :guilabel:`Merge policy`
684+
685+
* Under :guilabel:`Range`, you can set the following options:
686+
687+
* :guilabel:`Minimum`: set the minimum acceptable value for the field.
688+
* :guilabel:`Maximum`: set the maximum acceptable value for the field.
689+
* Check the |checkbox| :guilabel:`Inclusive` if you want to include the boundary values in the acceptable range.
690+
691+
* :guilabel:`Values`: click the |symbologyAdd| :sup:`Add row` or |symbologyRemove| :sup:`Remove row` to manage
692+
the list of acceptable values for the field.
693+
* :guilabel:`Pattern`: define the :guilabel:`Glob pattern` using wildcard characters.
694+
695+
Update and delete field domains by selecting the desired domain from the list and
696+
right-clicking to access the context menu options.
697+
You can also view the details of the domain assigned to a field.
698+
699+
.. note::
700+
701+
When loading vector layers into QGIS, fields with |sourceFields| :guilabel:`Field Domains`
702+
(such as those defined in a GeoPackage or ESRI File Geodatabase) are automatically
703+
detected. These domains are database-level constraints, meaning they are enforced
704+
by the database itself and apply across different applications, not just QGIS.
705+
654706
.. index:: PostgreSQL; PostGIS; ST_Shift_Longitude
655707

656708
Layers crossing 180° longitude
@@ -721,3 +773,9 @@ and a -180..180° representation of a 0..360° data.
721773
:width: 1em
722774
.. |setProjection| image:: /static/common/mActionSetProjection.png
723775
:width: 1.5em
776+
.. |sourceFields| image:: /static/common/mSourceFields.png
777+
:width: 1.5em
778+
.. |symbologyAdd| image:: /static/common/symbologyAdd.png
779+
:width: 1.5em
780+
.. |symbologyRemove| image:: /static/common/symbologyRemove.png
781+
:width: 1.5em

0 commit comments

Comments
 (0)