I think the easiest way is to use the "parameter" functionality.
http://www.liquibase.org/manual/changelog_parameters

 

You can make your changeset as schemaName="${schema}" and then pass the
schema you want into liquibase.

 

Nathan

 

From: Pradnya Gawade [mailto:[email protected]] 
Sent: Tuesday, March 03, 2009 12:20 PM
To: [email protected]
Subject: [Liquibase-user] liquibase: specify schema name specific to
database

 

Hi,

I am trying to have a common changeLog xml file for two databases
Postgres and Oracle. Probably I have found the way to manage all other
database specific syntax in the xml file except the schema names. 
I want to have different schema name for oracle and postgres as
'schemaName' attribute inside <createTable> tag . Is there any simple
way to do this? I thought about using the <preConditions> tag to contain
different <createTable> tag for different database (with the difference
of schema name specific to database inside <createTable> tag) but this
do not look to be the optimum way to me as there are so many tables.
Could any one suggest some better way if it is there. Thanks in advance.

-- Pradnya

------------------------------------------------------------------------------
Open Source Business Conference (OSBC), March 24-25, 2009, San Francisco, CA
-OSBC tackles the biggest issue in open source: Open Sourcing the Enterprise
-Strategies to boost innovation and cut costs with open source participation
-Receive a $600 discount off the registration fee with the source code: SFAD
http://p.sf.net/sfu/XcvMzF8H
_______________________________________________
Liquibase-user mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/liquibase-user

Reply via email to