|
View:
New views
1 Messages
—
Rating Filter:
Alert me
|
|
|
New Topic: ChangeLog Chain Example requiredA new topic, 'ChangeLog Chain Example required', has been made on a board you are watching.
You can see it at http://liquibase.org/forum/index.php?topic=47.new#new The text of the topic is shown below: Hi Nathan, I'm exploring you changes, you made for adding fine tuning sql generation through SqlGeneratorChain facility. And already run into situation, where it might to be applied. Running java-dbtest against MSSQL 2000 getting the error (see at the end of post) The server supports only to the following [ ON DELETE { CASCADE | NO ACTION } ] [ ON UPDATE { CASCADE | NO ACTION } ] By RESTRICT I think the clauses ON DELETE/ON UPDATE must be omitted. Give some ideas, how sql generation may be customized to this case Thanks. liquibase.exception.MigrationFailedException: Migration failed for change set liquibase-test3201895695241807216.xml::1244876788296-49::otaranenko (generated): Reason: liquibase.exception.JDBCException: Error executing SQL ALTER TABLE [liquibase].[address] ADD CONSTRAINT [FK_ADDRESS_STATE] FOREIGN KEY ([state]) REFERENCES [liquibase].[state]([id]) ON UPDATE RESTRICT ON DELETE RESTRICT: Caused By: Error executing SQL ALTER TABLE [liquibase].[address] ADD CONSTRAINT [FK_ADDRESS_STATE] FOREIGN KEY ([state]) REFERENCES [liquibase].[state]([id]) ON UPDATE RESTRICT ON DELETE RESTRICT: Caused By: Incorrect syntax near the keyword 'RESTRICT'. at liquibase.changelog.ChangeSet.execute(ChangeSet.java:234) at liquibase.changelog.visitor.UpdateVisitor.visit(UpdateVisitor.java:26) at liquibase.changelog.ChangeLogIterator.run(ChangeLogIterator.java:39) at liquibase.Liquibase.update(Liquibase.java:113) at liquibase.dbtest.AbstractSimpleChangeLogRunnerTest.testRerunDiffChangeLog(AbstractSimpleChangeLogRunnerTest.java:298) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at junit.framework.TestCase.runTest(TestCase.java:164) at junit.framework.TestCase.runBare(TestCase.java:130) at junit.framework.TestResult$1.protect(TestResult.java:110) at junit.framework.TestResult.runProtected(TestResult.java:128) at junit.framework.TestResult.run(TestResult.java:113) at junit.framework.TestCase.run(TestCase.java:120) at junit.framework.TestSuite.runTest(TestSuite.java:228) at junit.framework.TestSuite.run(TestSuite.java:223) at org.junit.internal.runners.OldTestClassRunner.run(OldTestClassRunner.java:35) at org.eclipse.jdt.internal.junit4.runner.JUnit4TestReference.run(JUnit4TestReference.java:46) at org.eclipse.jdt.internal.junit.runner.TestExecution.run(TestExecution.java:38) at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:467) at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:683) at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:390) at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:197) Caused by: liquibase.exception.JDBCException: Error executing SQL ALTER TABLE [liquibase].[address] ADD CONSTRAINT [FK_ADDRESS_STATE] FOREIGN KEY ([state]) REFERENCES [liquibase].[state]([id]) ON UPDATE RESTRICT ON DELETE RESTRICT at liquibase.executor.DefaultExecutor.execute(DefaultExecutor.java:59) at liquibase.executor.DefaultExecutor.execute(DefaultExecutor.java:89) at liquibase.database.AbstractDatabase.execute(AbstractDatabase.java:1443) at liquibase.database.AbstractDatabase.executeStatements(AbstractDatabase.java:1430) at liquibase.changelog.ChangeSet.execute(ChangeSet.java:210) ... 23 more Caused by: com.microsoft.sqlserver.jdbc.SQLServerException: Incorrect syntax near the keyword 'RESTRICT'. at com.microsoft.sqlserver.jdbc.SQLServerException.makeFromDatabaseError(Unknown Source) at com.microsoft.sqlserver.jdbc.IOBuffer.processPackets(Unknown Source) at com.microsoft.sqlserver.jdbc.SQLServerStatement.getNextResult(Unknown Source) at com.microsoft.sqlserver.jdbc.SQLServerStatement.sendExecute(Unknown Source) at com.microsoft.sqlserver.jdbc.SQLServerStatement.doExecute(Unknown Source) at com.microsoft.sqlserver.jdbc.SQLServerStatement.execute(Unknown Source) at liquibase.executor.DefaultExecutor$1ExecuteStatementCallback.doInStatement(DefaultExecutor.java:80) at liquibase.executor.DefaultExecutor.execute(DefaultExecutor.java:52) ... 27 more Unsubscribe to new topics from this board by clicking here: http://liquibase.org/forum/index.php?action=notifyboard;board=2.0 Regards, The LiquiBase Community Forum Team. ------------------------------------------------------------------------------ Crystal Reports - New Free Runtime and 30 Day Trial Check out the new simplified licensing option that enables unlimited royalty-free distribution of the report engine for externally facing server and web deployment. http://p.sf.net/sfu/businessobjects _______________________________________________ Liquibase-devel mailing list Liquibase-devel@... https://lists.sourceforge.net/lists/listinfo/liquibase-devel |
| Free embeddable forum powered by Nabble | Forum Help |