Updating of detail tabs besides list of tables works correctly again.
Had stopped working because the catalog now behaves a little different, returning nullptr instead of an invalid element.
This commit is contained in:
parent
fcb191f2cc
commit
52011a9842
12 changed files with 114 additions and 92 deletions
|
|
@ -20,6 +20,7 @@ public:
|
|||
int32_t typmod = -1;
|
||||
bool notnull = false;
|
||||
bool hasdef = false;
|
||||
bool isdropped = false;
|
||||
Oid collation = InvalidOid;
|
||||
QString acl;
|
||||
QString options;
|
||||
|
|
|
|||
|
|
@ -10,7 +10,7 @@ std::string PgAttributeContainer::getLoadQuery() const
|
|||
{
|
||||
return R"__(
|
||||
SELECT attrelid, attname, atttypid, attstattarget,
|
||||
attnum, attndims, atttypmod, attnotnull, atthasdef,
|
||||
attnum, attndims, atttypmod, attnotnull, atthasdef, attisdropped,
|
||||
attcollation, attacl, attoptions, pg_get_expr(adbin, adrelid) AS def_value
|
||||
FROM pg_catalog.pg_attribute
|
||||
LEFT JOIN pg_attrdef ON attrelid=adrelid AND attnum=adnum)__";
|
||||
|
|
@ -21,7 +21,7 @@ PgAttribute PgAttributeContainer::loadElem(const Pgsql::Row &row)
|
|||
Pgsql::Col col(row);
|
||||
PgAttribute v;
|
||||
col >> v.relid >> v.name >> v.typid >> v.stattarget
|
||||
>> v.num >> v.ndims >> v.typmod >> v.notnull >> v.hasdef
|
||||
>> v.num >> v.ndims >> v.typmod >> v.notnull >> v.hasdef >> v.isdropped
|
||||
>> v.collation >> v.acl >> v.options >> v.defaultValue;
|
||||
return v;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue