Error: Table "PG_ATTRDEF" not found; SQL statement:
I'm using
> h2-1.2.129.jar
> psqlodbc_08_04_0200.zip
>Access 2007
thanks
F.D.
Trace details *******************************************
Connect
Init
StartupMessage
version 196608 (3.0)
param database=mimweb
param user=MIMWEB
param DateStyle=ISO
param extra_float_digits=2
param geqo=on
param client_encoding=UTF8
PasswordMessage
Query
select oid, typbasetype from pg_type where typname = 'lo';
Query
SELECT Config, nValue FROM MSysConf;
org.h2.jdbc.JdbcSQLException: Table "MSYSCONF" not found; SQL
statement:
SELECT Config, nValue FROM MSysConf [42102-129]
at org.h2.message.DbException.getJdbcSQLException(DbException.java:
317)
at org.h2.message.DbException.get(DbException.java:168)
at org.h2.message.DbException.get(DbException.java:145)
at org.h2.command.Parser.readTableOrView(Parser.java:4334)
at org.h2.command.Parser.readTableFilter(Parser.java:1002)
at org.h2.command.Parser.parseSelectSimpleFromPart(Parser.java:1530)
at org.h2.command.Parser.parseSelectSimple(Parser.java:1627)
at org.h2.command.Parser.parseSelectSub(Parser.java:1524)
at org.h2.command.Parser.parseSelectUnion(Parser.java:1369)
at org.h2.command.Parser.parseSelect(Parser.java:1357)
at org.h2.command.Parser.parsePrepared(Parser.java:396)
at org.h2.command.Parser.parse(Parser.java:279)
at org.h2.command.Parser.parse(Parser.java:251)
at org.h2.command.Parser.prepareCommand(Parser.java:223)
at org.h2.engine.Session.prepareLocal(Session.java:422)
at org.h2.engine.Session.prepareCommand(Session.java:383)
at org.h2.jdbc.JdbcConnection.prepareCommand(JdbcConnection.java:
1071)
at org.h2.jdbc.JdbcStatement.executeInternal(JdbcStatement.java:163)
at org.h2.jdbc.JdbcStatement.execute(JdbcStatement.java:151)
at org.h2.server.pg.PgServerThread.process(PgServerThread.java:340)
at org.h2.server.pg.PgServerThread.run(PgServerThread.java:76)
at java.lang.Thread.run(Thread.java:619)
Query
select relname, nspname, relkind from pg_catalog.pg_class c,
pg_catalog.pg_namespace n where relkind in ('r', 'v') and n.oid =
relnamespace order by nspname, relname;
Query
select c.relhasrules, c.relkind, c.relhasoids from
pg_catalog.pg_namespace u, pg_catalog.pg_class c where u.oid =
c.relnamespace and c.relname = E'TMIMAMB' and u.nspname = E'MIMWEB';
Query
select n.nspname, c.relname, a.attname, a.atttypid, t.typname,
a.attnum, a.attlen, a.atttypmod, a.attnotnull, c.relhasrules,
c.relkind, c.oid, d.adsrc, case t.typtype when 'd' then t.typbasetype
else 0 end, t.typtypmod from (((pg_catalog.pg_class c inner join
pg_catalog.pg_namespace n on n.oid = c.relnamespace and c.relname like
E'TMIMAMB' and n.nspname like E'MIMWEB') inner join
pg_catalog.pg_attribute a on (not a.attisdropped) and a.attnum > 0 and
a.attrelid = c.oid) inner join pg_catalog.pg_type t on t.oid =
a.atttypid) left outer join pg_attrdef d on a.atthasdef and d.adrelid
= a.attrelid and d.adnum = a.attnum order by n.nspname, c.relname,
attnum;
org.h2.jdbc.JdbcSQLException: Column "T.TYPTYPMOD" not found; SQL
statement:
select n.nspname, c.relname, a.attname, a.atttypid, t.typname,
a.attnum, a.attlen, a.atttypmod, a.attnotnull, c.relhasrules,
c.relkind, c.oid, d.adsrc, case t.typtype when 'd' then t.typbasetype
else 0 end, t.typtypmod from (((pg_catalog.pg_class c inner join
pg_catalog.pg_namespace n on n.oid = c.relnamespace and c.relname like
E'TMIMAMB' and n.nspname like E'MIMWEB') inner join
pg_catalog.pg_attribute a on (not a.attisdropped) and a.attnum > 0 and
a.attrelid = c.oid) inner join pg_catalog.pg_type t on t.oid =
a.atttypid) left outer join pg_attrdef d on a.atthasdef and d.adrelid
= a.attrelid and d.adnum = a.attnum order by n.nspname, c.relname,
attnum [42122-129]
at org.h2.message.DbException.getJdbcSQLException(DbException.java:
317)
at org.h2.message.DbException.get(DbException.java:168)
at org.h2.message.DbException.get(DbException.java:145)
at org.h2.expression.ExpressionColumn.optimize(ExpressionColumn.java:
126)
at org.h2.command.dml.Select.prepare(Select.java:714)
at org.h2.command.Parser.prepareCommand(Parser.java:224)
at org.h2.engine.Session.prepareLocal(Session.java:422)
at org.h2.engine.Session.prepareCommand(Session.java:383)
at org.h2.jdbc.JdbcConnection.prepareCommand(JdbcConnection.java:
1071)
at org.h2.jdbc.JdbcStatement.executeInternal(JdbcStatement.java:163)
at org.h2.jdbc.JdbcStatement.execute(JdbcStatement.java:151)
at org.h2.server.pg.PgServerThread.process(PgServerThread.java:340)
at org.h2.server.pg.PgServerThread.run(PgServerThread.java:76)
at java.lang.Thread.run(Thread.java:619)
^CException in thread "Thread-16" java.lang.AbstractMethodError:
it.ubi.mimweb.h2.AutoInc.close()V
at org.h2.schema.TriggerObject.close(TriggerObject.java:373)
at org.h2.engine.Database.close(Database.java:1031)
at org.h2.engine.DatabaseCloser.run(DatabaseCloser.java:80)
ODBC: Chiamata non riuscita ( Call failed )
Error while executing the query ( #7 )
On 22 Feb, 18:02, Sergi Vladykin <sergi.vlady...@googlemail.com>
wrote:
You have used version psqlodbc_08_04_0200 but the last version I tried
was psqlodbc-08_02* - that's probably the reason.
I guess the main problem is that the column T.TYPTYPMOD is missing.
This is a bug in H2, in the file pg_catalog.sql. This will be fixed in
the next release. If you want to test it now you would have to replace
the file pg_catalog.sql from here:
http://h2database.googlecode.com/svn/trunk/h2/src/main/org/h2/server/pg/pg_catalog.sql
- and build H2 yourself. In any case you will also have to drop the
pg_catalog first using "drop schema pg_catalog" and then re-connect.
I'm not sure if this will completely solve the problem however - there
might be more columns missing. Please send a mail if so.
Another problem might be that trigger class it.ubi.mimweb.h2.AutoInc
doesn't implement close(). This is due to a change in the trigger
interface in H2 in version 1.2.129. As far as I see this is not a big
problem, but you should probably fix that in the near future.
By the way, the message about "MSYSCONF" is not really a problem, you
can ignore that.
Regards,
Thomas
I build the version get from the svn trunk:
"svn checkout http://h2database.googlecode.com/svn/trunk/ h2database-
re"
all the problems seems resolved.
many thanks
regards
Francesco.
On 23 Feb, 13:02, Thomas Mueller <thomas.tom.muel...@gmail.com> wrote:
> Hi,
>
> You have used version psqlodbc_08_04_0200 but the last version I tried
> was psqlodbc-08_02* - that's probably the reason.
>
> I guess the main problem is that the column T.TYPTYPMOD is missing.
> This is a bug in H2, in the file pg_catalog.sql. This will be fixed in
> the next release. If you want to test it now you would have to replace
> the file pg_catalog.sql from here:http://h2database.googlecode.com/svn/trunk/h2/src/main/org/h2/server/...
> all the problems seems resolved.
Thanks a lot for your help!
Regards,
Thomas
I'm not sure I understood the solution...
I think I set up the PostgreSQL ODBC driver correctly in the System DSN (at least hittling [ Test ] returns "Connection Successful".)
In Access, when I go to Link tables, select ODBC, Machine Data Source: PostgreSQL (from ODBC Data Sources), it brings up the tables (all listed as PUBLIC):
...but selecting one and clicking [ OK ] returns the following error:
This is what I see after trying to link tables to the H2 database from Access. Not sure how to run trace and what to post.
My setup:
H2: h2-1.3.170
psqlodbc: psqlodbc_09_01_0200-1
Access 2003: 11.0.8321
Any help would be greatly appreciated.
Thanks,
Drew
--
You received this message because you are subscribed to the Google Groups "H2 Database" group.
To unsubscribe from this group and stop receiving emails from it, send an email to h2-database...@googlegroups.com.
To post to this group, send email to h2-da...@googlegroups.com.
Visit this group at http://groups.google.com/group/h2-database?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.
--
You received this message because you are subscribed to the Google Groups "H2 Database" group.
To unsubscribe from this group and stop receiving emails from it, send an email to h2-database...@googlegroups.com.
To post to this group, send email to h2-da...@googlegroups.com.
Visit this group at http://groups.google.com/group/h2-database.
For more options, visit https://groups.google.com/d/optout.