Trying to reverse engineer an H2 db using postgres ODBC (V8.2 and up), seems that the pg_catalog is not fully compatible with the pgodbc (tried with V8.2 to 9). Views are missing fields, functions missing from the schema pg_catalog. Here two such errors: [14.859]ERROR from backend during send_query: 'MFunction "FORMAT_TYPE" not found; SQL statement: select a.attname, a.attnum, ty.typname, a.attlen, a.attnotnull, a.atttypmod, (select ad.adsrc from pg_attrdef ad where ad.adrelid = a.attrelid and ad.adnum = a.attnum), (select format_type(a.atttypid, atttypmod)), (select col_description(t.oid, a.attnum)) from pg_attribute a, pg_class t, pg_namespace o, pg_type ty where a.attnum > 0 and attrelid = t.oid and (t.relkind = 'r' or t.relkind = 'v') and t.relnamespace = o.oid and o.nspname = 'VISITE_SCHEMA' and ty.oid = a.atttypid and t.relname = 'DOCUMENT' [90022-166]' [14.875]ERROR from backend during send_query: 'Dorg.h2.jdbc.JdbcSQLException: Function "FORMAT_TYPE" not found; SQL statement: select a.attname, a.attnum, ty.typname, a.attlen, a.attnotnull, a.atttypmod, (select ad.adsrc from pg_attrdef ad where ad.adrelid = a.attrelid and ad.adnum = a.attnum), (select format_type(a.atttypid, atttypmod)), (select col_description(t.oid, a.attnum)) from pg_attribute a, pg_class t, pg_namespace o, pg_type ty where a.attnum > 0 and attrelid = t.oid and (t.relkind = 'r' or t.relkind = 'v') and t.relnamespace = o.oid and o.nspname = 'VISITE_SCHEMA' and ty.oid = a.atttypid and t.relname = 'DOCUMENT' [90022-166]' [14.875]STATEMENT ERROR: func=SC_execute, desc='(null)', errnum=7, errmsg='Error while executing the query'
and [20.189]ERROR from backend during send_query: 'MColumn "C.RELTABLESPACE" not found; SQL statement: select t.spcname from pg_class c, pg_tablespace t, pg_namespace n where c.relname = 'DOCUMENT' and n.nspname = 'VISITE_SCHEMA' and c.relnamespace = n.oid and c.reltablespace = t.oid [42122-166]' [20.189]ERROR from backend during send_query: 'Dorg.h2.jdbc.JdbcSQLException: Column "C.RELTABLESPACE" not found; SQL statement: select t.spcname from pg_class c, pg_tablespace t, pg_namespace n where c.relname = 'DOCUMENT' and n.nspname = 'VISITE_SCHEMA' and c.relnamespace = n.oid and c.reltablespace = t.oid [42122-166]' [20.189]STATEMENT ERROR: func=SC_execute, desc='(null)', errnum=7, errmsg='Error while executing the query' the script pg_catalog should be reworked, and some functions to be added for a full compatibility with postgres ODBC driver. Thanks -- You received this message because you are subscribed to the Google Groups "H2 Database" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/h2-database?hl=en.
