On the list of indexes of a table show which were created as part of the creation of a constraint

The explicit column is true when the index was manually created
In SQL only a comment is given that the index was implicitly created
This commit is contained in:
eelke 2021-04-11 07:56:37 +02:00
parent 60bbb4c445
commit fd5ad9bbf0
6 changed files with 56 additions and 20 deletions

View file

@ -9,7 +9,6 @@
class PgIndex : public PgNamespaceObject {
public:
// Oid indexrelid = InvalidOid; // oid of pg_class for this index
Oid relid = InvalidOid; // oid of table (pg_class) where this is an index on
int16_t natts = 0;
bool isunique = false;
@ -34,15 +33,14 @@ public:
using PgNamespaceObject::PgNamespaceObject;
QString getAm() const;
// bool operator==(Oid _oid) const { return indexrelid == _oid; }
// //bool operator==(const QString &n) const { return name == n; }
// bool operator<(Oid _oid) const { return indexrelid < _oid; }
// bool operator<(const PgIndex &rhs) const { return indexrelid < rhs.indexrelid; }
QString createSql() const;
QString dropSql() const;
QString createSql() const override;
QString dropSql() const override;
QString typeName() const override;
/// Returns true when this index has been created as part of the creation
/// of a constaint.
bool isSupportingIndex() const;
};
#endif // PGINDEX_H