db-derby-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Dyre.Tjeldv...@Sun.COM
Subject Re: Hibernate: table/view does not exist
Date Wed, 26 Sep 2007 12:46:26 GMT
Mathias Conradt <mathias.conradt@gmail.com> writes:

> I try to exchange postgres with derby/javadb and created a derby
> database using ij (I'm new to derby).
> I use CONNECT 'jdbc:derby:realty;'; for the connection in ij
> and after the creation I can do selects on the table using ij.

The username you used (in ij) will determine which schema the table
ends up in. If you didn't specify a username it should end up in APP.

I don't know anything about Hibernate, but when you are in ij you
could run the following query to figure out where your table actually
has ended up:

select t.tablename, s.schemaname from sys.systables t, sys.sysschemas s where t.tablename
= 'USERDATA' and t.schemaid = s.schemaid;

This should also tell you if you have multiple copies of USERDATA in
different schemas. 

You don't have to rely on the default schema for the user you connect
as. You can create your own schema (CREATE SCHEMA ...) and explicitly
set that as you default schema (SET SCHEMA ...)


View raw message