pgr_isColumnIndexed¶
Name¶
pgr_isColumnIndexed — Check if a column in a table is indexed.
Note
This function is intended for the developer’s aid.
Synopsis¶
Returns true when the column “col” in table “tab” is indexed.
boolean pgr_isColumnIndexed(text tab, text col);
Description¶
tab: | text Table name with or without schema component. |
---|---|
col: | text Column name to be checked for. |
Returns:
- true when the column “col” in table “tab” is indexed.
- false when:
- The table “tab” is not found or
- Column “col” is not found in table “tab” or
- Column “col” in table “tab” is not indexed
History
- New in version 2.0.0
Examples¶
SELECT pgr_isColumnIndexed('edge_table','x1');
pgr_iscolumnindexed
---------------------
f
(1 row)
SELECT pgr_isColumnIndexed('public.edge_table','cost');
pgr_iscolumnindexed
---------------------
f
(1 row)
The example use the Sample Data network.
See Also¶
- Developer’s Guide for the tree layout of the project.
- pgr_isColumnInTable to check only for the existance of the column in the table.
- pgr_getColumnName to get the name of the column as is stored in the postgres administration tables.
- pgr_getTableName to get the name of the table as is stored in the postgres administration tables.