Quantcast
Channel: Liquibase Forums
Viewing all 2993 articles
Browse latest View live

Re : Avoid schema/catalog sql generation

$
0
0
Actually it was a misuntersood about how generator works, there is not any problem with the code!

Custom Parameter Values Corrupt Computed Changeset Checksum

$
0
0
I created a changelog file containing a changeset that inserts a record into a table with custom values passed in on the command line. For instance, I'd pass a parameter to execute liquibase from the command by specifying the custom parameter by including "-Dparam=value". What I've confirmed is that the checksum performed on the changeset varies depending on the value of the parameter. I attempted to change the column definition to use the valueComputed attribute since it seems to handle this situation (i.e. date functions obviously generate different values on subsequent executions) but that did not work.

Am I missing something/doing something wrong, or is this a defect?

Sample of insert from changeset:

<insert tableName="TABLE_ONE">
    ...
    <column name="TEST" value="${param}" />
    ...
</insert>

Encrypted passwrods per environment

$
0
0
Is it possible to use maven encrypted files in a liquibase properties file and have maven decrypt them during runtime? I tried adding an encrypted password to a properties file and it doesn't correctly decrypt it.

eg:
  1. password: {uq15QwM5GrUHf8afjGiJjHRg2CFQbrx+tovHSt2sATM=}
 Gives the error:

org.apache.maven.lifecycle.LifecycleExecutionException: Failed to execute goal org.liquibase:liquibase-maven-plugin:3.0.5:update (******) on project db-update: Error setting up or running Liquibase: java.sql.SQLException: ORA-01017: invalid username/password; logon denied


Re : Avoid schema/catalog sql generation

$
0
0
Good, thanks for the update.

Nathan

Re : Bug CORE-1236 should be reopened?

$
0
0
Sorry for late reply.
I was using liquibase:diff and then liquibase:updateSQL

Is it possible to compare an existing DB schema against a changelog file?

$
0
0
Looking through the forum posts I've seen that my above question had been asked several times over the past years.
Now I was wondering if such a feature has been implemented yet or if it is considered for any time soon?


Re : Bug CORE-1236 should be reopened?

$
0
0
I reopened the issue and will look into it more. I am working on improving testing which is part of why I hadn't replied yet. I'll let you know if I have questions trying to reproduce it.

Nathan

Re : Custom Parameter Values Corrupt Computed Changeset Checksum

$
0
0
Is is expected behavior for the checksum to be based on the value after replacing ${param} because the SQL that was executed was different than what would be computed now. I created  https://liquibase.jira.com/browse/CORE-1835 to track the feature to control that.

You can disable checksum validation by using a <validCheckSum>any<validCheckSum> tag.

Nathan 

Re : Encrypted passwrods per environment

$
0
0
There is no direct support for encrypted passwords in liquibase, but I've heard the standard maven encrypted password works. I don't use maven to know what it takes to set that up, though.

Nathan

Re : Extend Changeset

$
0
0
Those steps sound about right. You probably don't want to try to modify dbchangelog.xsd but instead use a separate XSD/namespace for your new attributes.

Nathan

Re : Mapping for INTEGER on Oracle changed between Liquibase 2 and 3

$
0
0
Thanks, I created https://liquibase.jira.com/browse/CORE-1836 to track the change.

Data type mapping is something that isn't as clean as I woud like and I am planning on addressing in the near future. 

For now, your easiest option is to use changelog parameters and use something like <column name="ID" type="${integer}">

Then you can define at the top of your changelog <property name="integer" value="numeric(38,0)" dbms="oracle"/>

Alternately, you could create a subclass of liquibase.datatype.core.IntType with a higher return value for getPriority() and return NUMERIC(38,0) from toDatabaseDataType()

Nathan

Re : Custom Parameter Values Corrupt Computed Changeset Checksum

$
0
0
Ah. I missed that attribute in the documentation somehow. Thank you for pointing that out. 

Re : Is it possible to compare an existing DB schema against a changelog file?

$
0
0
Yes, it is a popular request, but it hasn't been implemented yet. The biggest problem is that to solve it for the general case we need an SQL parser in order to handle <sql> <sqlFile> and <modifySql> blocks. 

It would be possible to do in a subset of all changeSets, but it hasn't made it to the top of my priority list yet and nobody has contributed anything yet.

Nathan

Custom Extensions not available in OSGi build

$
0
0
It seems that the OSGi integrated build of Liquibase does not include custom extensions.
In my case, the hibernate integration is needed to run with the OSGi build.

From my point of view, all custom extensions should be compiled as fragments (and use the main OSGi Liquibase bundle as their host).

New Extension: Liquibase Vertica support


int array type for HQSLDB

$
0
0
Hello,

I'm trying to generate a table with an int array column for HSQLDB.

<changeSet id="20131120-001-create-test-table" author="nanchen" dbms="hsqldb">
<createTable tableName="test_table">
<column name="id" type="bigint">
<constraints nullable="false" />
</column>
<column name="units" type="int array"/>
</createTable>
</changeSet>

The generated DDL is:
CREATE TABLE test_table (id BIGINT NOT NULL, units INT)

It seams that liquibase interprets the type "int array" in "INT". Is it possible to bypass the interpretation of liquibase to allow arbitrary types?

Cheers,
Stan.

Using Liquibase to migrate selective data.

$
0
0
Hi,

We have two identical database (say A and B), and wonder if its possible to use liquibase to migrate selective data from A to B.

A is a read/write database and B is read-only. We have written a system where a users make changes to A and then 'copy' selective changes made on A to B.

I was wondering if it was possible/good idea to use liquibase to do this.

We already use liquibase to manage changes to our database structure when deploying our system.

Thanks,
Jack.

Database Tag

$
0
0
Hi All ,

I am trying to tag the database for rollback purposes and below is the syntax that I am using in the changelog file.

<changeSet author="Major Version" id="2.0">
          <tagDatabase tag="version_2.0"/>

The issue that I see is after applying this tag/changeset it also updates the previous changeset also with the Tag.

Below is the extract from the databasechangelog table  , function51 is a changeset from a previous run

===> function51    sr    ./db-changelog.xml    05-APR-14 12.34.46.975900000    15    EXECUTED    7:5616f4adba7690fafd882b3a607c3eca    sqlFile        version_2.0    3.1.1

===>2.0    Major Version    ./db-ApplyTag.xml    05-APR-14 12.37.24.140637000    16    EXECUTED    7:97fe9eb435a72fdfbe27647efa5be97d    tagDatabase        version_2.0    3.1.1

Has anybody faced the issue , any solution / workaround ?

Btw I am using Liquibase 3.1.1

Thanks.
 

generateChangeLog ignores foreign keys, DB engine types (InnoDB)

$
0
0
Hi,

I have a mysql database with some MyISAM and some InnoDB tables, foreign key relations between some of the InnoDB tables. When I do generateChangeLog, there are no foreign-keys in changelog.xml. Is this a bug? Or is this a missing feature?

The DB engine is also "lost" in changelog.xml.

PS: it's impossible to log in to the forum using the Google as OpenId (redirects to 404 page)

Ant task updates

$
0
0
I have been browsing the Jira tickets and noticed a few regarding the ant task. Here are the ones I am looking at:

https://liquibase.jira.com/browse/CORE-1672 - Split Liquibase into Liquibase-core and Liquibase-ant
https://liquibase.jira.com/browse/CORE-776 - Using ant tasks when called from another ant

I was wondering if you still want this tickets worked on. Specificly the one about splitting the ant tasks into its own module. If so I would be happy to tackle this. I have worked with custom ant tasks before. If you need a reference, you can look at my Github where I have my own ant task.

Also, I would also like to update the ant task to bring it up to a more moden version of Ant which will make a lot of things easier, hopefully reduce the code size, and allow me to write unit/integration tests.

Let me know if all of this sounds ok. I don't want to do any work that you don't find useful or needed.
Viewing all 2993 articles
Browse latest View live


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>