Postgrsql 12

add PG12 support.
Bug fix
This commit is contained in:
levinsv 2019-10-05 16:38:43 +05:00
parent 10e9e0229c
commit 7e10968209
14 changed files with 89 additions and 25 deletions

View file

@ -492,7 +492,7 @@ void pgObject::ShowDependencies(frmMain *form, ctlListView *Dependencies, const
* END
*/
ShowDependency(GetDatabase(), Dependencies,
wxT("SELECT DISTINCT dep.deptype, dep.refclassid, cl.relkind, ad.adbin, ad.adsrc, \n")
wxT("SELECT DISTINCT dep.deptype, dep.refclassid, cl.relkind, ad.adbin, pg_get_expr(ad.adbin,0) adsrc, \n")
wxT(" CASE WHEN cl.relkind IS NOT NULL THEN cl.relkind || COALESCE(dep.refobjsubid::text, '')\n")
wxT(" WHEN tg.oid IS NOT NULL THEN 'T'::text\n")
wxT(" WHEN ty.oid IS NOT NULL THEN 'y'::text\n")
@ -663,7 +663,7 @@ void pgObject::ShowDependents(frmMain *form, ctlListView *referencedBy, const wx
* END
*/
ShowDependency(GetDatabase(), referencedBy,
wxT("SELECT DISTINCT dep.deptype, dep.classid, cl.relkind, ad.adbin, ad.adsrc, \n")
wxT("SELECT DISTINCT dep.deptype, dep.classid, cl.relkind, ad.adbin, pg_get_expr(ad.adbin,0) adsrc, \n")
wxT(" CASE WHEN cl.relkind IS NOT NULL THEN cl.relkind || COALESCE(dep.objsubid::text, '')\n")
wxT(" WHEN tg.oid IS NOT NULL THEN 'T'::text\n")
wxT(" WHEN ty.oid IS NOT NULL THEN 'y'::text\n")