db-torque-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Damien SAUVAGEOT" <dsauvag...@omnikles.com>
Subject RE: sql2xml postgresql
Date Mon, 08 Mar 2004 08:57:08 GMT
Hello benjamin,

Indeed it worked. Thx a lot. torque.database.schema is relevant for postgresql. In my case,
the schema was public.
so adding torque.database.schema = public, I was able to retrieve the XML of my database.


thx
Damien



-----Message d'origine-----
De : Benjamin Yu [mailto:BenjaminY@InformativeResearch.com]
Envoyé : vendredi 5 mars 2004 18:48
À : 'Apache Torque Users List'
Objet : RE: sql2xml postgresql


> So it apparently does not have any impact on postgresql DB. 

I can't remember when the feature was introduced, but postgresql supports
schemas (essentially namespaces for your db objects).
http://www.postgresql.org/docs/7.4/static/sql-createschema.html

Here's an example of what I'm talking about if you were to create the
following tables in postgresql then run the torque jdbc goal:

No schema:

	create table mytable1 ( x integer );

Using Schema:
	create schema myschema;
	create table myschema.mytable2 ( x integer );

# Get mytable1
torque.database.schema=
# Get mytable1
torque.database.schema=public
# Get mytable2
torque.database.schema=myschema

You can find out what namespace the tables are in by connecting and doing a
"select schemaname, tablename from pg_tables;"

Does this help?

-Ben

-----Original Message-----
From: Damien SAUVAGEOT [mailto:dsauvageot@omnikles.com]
Sent: Friday, March 05, 2004 6:18 AM
To: Apache Torque Users List
Subject: RE: sql2xml postgresql


Hello Andras,

thx for the answer. I found some information here
http://db.apache.org/torque/properties-reference.html
about this properties :
   	 Used by the JDBC -> XML process, and by the SQL Ant Task that will
initialize your target database with the generated SQL. This is only used by
Oracle at this time. This must be UPPERCASE!
So it apparently does not have any impact on postgresql DB. 
I did not find any more information on google. I tried using schema,
schema.xml, xx-schema.xml, dbname, dbname-schema, dbname-schema.xml values
but it didn't make any  differences. 
I don't understand what this property is used for.

Damien



-----Message d'origine-----
De : Andras Balogh [mailto:andras@reea.net]
Envoyé : vendredi 5 mars 2004 14:46
À : Apache Torque Users List
Objet : Re: sql2xml postgresql


    Hello,

I think at jdbc target the problem is the schema:

"[torque-jdbc-transform] schema : ${databaseSchema}"

You should specify in build.properties:
torque.database.schema =
but i don't know what this vaules should be for postgres maybe the owner
of the tables?
 (i.e. the username who created them)

Hope it helps,
Andras.






---------------------------------------------------------------------
To unsubscribe, e-mail: torque-user-unsubscribe@db.apache.org
For additional commands, e-mail: torque-user-help@db.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: torque-user-unsubscribe@db.apache.org
For additional commands, e-mail: torque-user-help@db.apache.org

---------------------------------------------------------------------
To unsubscribe, e-mail: torque-user-unsubscribe@db.apache.org
For additional commands, e-mail: torque-user-help@db.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: torque-user-unsubscribe@db.apache.org
For additional commands, e-mail: torque-user-help@db.apache.org


Mime
View raw message