diff --git a/pglablib/catalog/PgAttribute.cpp b/pglablib/catalog/PgAttribute.cpp index bfb4724..3e697d8 100644 --- a/pglablib/catalog/PgAttribute.cpp +++ b/pglablib/catalog/PgAttribute.cpp @@ -28,7 +28,7 @@ QString PgAttribute::columnDefinition(const PgDatabaseCatalog &cat) const if (hasdef) sql += " DEFAULT " % defaultValue; - if (identity != ' ') { + if (identity != '\0') { sql += " GENERATED "; if (identity == 'a') sql += "ALWAYS"; else if (identity == 'd') sql += "BY DEFAULT"; diff --git a/pglablib/catalog/PgAttribute.h b/pglablib/catalog/PgAttribute.h index 1e0cd8a..de887b2 100644 --- a/pglablib/catalog/PgAttribute.h +++ b/pglablib/catalog/PgAttribute.h @@ -22,7 +22,7 @@ public: int32_t typmod = -1; bool notnull = false; bool hasdef = false; - char identity = ' '; + char identity = '\0'; bool isdropped = false; bool islocal = true; Oid collation = InvalidOid;