Hello,
Looking at this, one thing that concerns me is the large amount of
overlap with dumpTableSchema() in pg_dump.
I wonder if it would make sense to separate the SQL generation logic
into frontend/backend-shared code so that it could also be used by
pg_dump. The catalog lookup would naturally remain separate, but
sharing the DDL generation itself would significantly reduce the
duplication.
By the way, a couple of comments use a Unicode RIGHTWARDS ARROW
(U+2192). Please use an ASCII equivalent instead.
Regards,
--
Kyotaro Horiguchi
NTT Open Source Software Center