# do not include create or insert into databasechangelog table when using updateSQL goal with maven

**URL:** <https://forum.liquibase.org/t/do-not-include-create-or-insert-into-databasechangelog-table-when-using-updatesql-goal-with-maven/2671>\
**Category:** Liquibase Development\
**Created:** [August 8, 2013, 10:57pm UTC](https://forum.liquibase.org/t/do-not-include-create-or-insert-into-databasechangelog-table-when-using-updatesql-goal-with-maven/2671 "2013-08-08T22:57:00Z")\
**Posts on this page:** 14\
**Page:** 1

<div class="post-metadata">

**Author:** ![Guest](https://avatars.discourse-cdn.com/v4/letter/g/8dc957/32.png) [@Guest](https://forum.liquibase.org/u/Guest)\
**Post date:** [August 8, 2013, 10:57pm UTC](https://forum.liquibase.org/t/do-not-include-create-or-insert-into-databasechangelog-table-when-using-updatesql-goal-with-maven/2671/1 "2013-08-08T22:57:00Z")

</div>

When i use the updateSQL goal to creat the sql statements, i do not want liquibase to add the insert into databasechangelog statements, Is there a way i can go that.

---

<div class="post-metadata">

**Author:** ![nvoxland](https://avatars.discourse-cdn.com/v4/letter/n/87869e/32.png) [@nvoxland](https://forum.liquibase.org/u/nvoxland)\
**Post date:** [August 8, 2013, 10:57pm UTC](https://forum.liquibase.org/t/do-not-include-create-or-insert-into-databasechangelog-table-when-using-updatesql-goal-with-maven/2671/2 "2013-08-08T22:57:00Z")

</div>

There is no way currently outside creating an extension to override the&nbsp;MarkChangeSetRanGenerator class.

Nathan

---

<div class="post-metadata">

**Author:** ![Guest](https://avatars.discourse-cdn.com/v4/letter/g/8dc957/32.png) [@Guest](https://forum.liquibase.org/u/Guest)\
**Post date:** [August 8, 2013, 10:57pm UTC](https://forum.liquibase.org/t/do-not-include-create-or-insert-into-databasechangelog-table-when-using-updatesql-goal-with-maven/2671/3 "2013-08-08T22:57:00Z")

</div>

Hi,  
I’ve just wanted to post the question but found this one, which is not so old. I’m in need for this functionality and have been for quite a time. I’m using it for making the SQL diff for minor version upgrade of our software where I only update the necessary tables as needed. It would be great if there were some new command like updateSqlRaw which will only ouptut the _real_ SQL changes without the one for databasechangelog.  
  
I would do it myself but I’m not a Java developer nor do I know the internals of liquibase. But I’ll gladly donate the implementation of this feature.  
  
Thank You  
  
Trigve

---

<div class="post-metadata">

**Author:** ![nvoxland](https://avatars.discourse-cdn.com/v4/letter/n/87869e/32.png) [@nvoxland](https://forum.liquibase.org/u/nvoxland)\
**Post date:** [August 8, 2013, 10:57pm UTC](https://forum.liquibase.org/t/do-not-include-create-or-insert-into-databasechangelog-table-when-using-updatesql-goal-with-maven/2671/4 "2013-08-08T22:57:00Z")

</div>

I just created&nbsp;[https://github.com/liquibase/liquibase-nochangelogupdate](https://github.com/liquibase/liquibase-nochangelogupdate)&nbsp;which is an extension to suppress inserting into the databasechangelog table.

Let me know how it works for you.

Nathan

---

<div class="post-metadata">

**Author:** ![Guest](https://avatars.discourse-cdn.com/v4/letter/g/8dc957/32.png) [@Guest](https://forum.liquibase.org/u/Guest)\
**Post date:** [August 8, 2013, 10:57pm UTC](https://forum.liquibase.org/t/do-not-include-create-or-insert-into-databasechangelog-table-when-using-updatesql-goal-with-maven/2671/5 "2013-08-08T22:57:00Z")

</div>

Thanks for reply and extension,  
unfortunately it looks like it is still ouputting&nbsp; the databasechangelock changes. I’m using the updateSql, this is my command I use inside my batch files (also with some variables which you could ignore):

1. call %BIN\_LIQUIBASE\_PATH%\liquibase.bat --defaultsFile=%BIN\_LIQUIBASE\_PATH%\liquibase.properties --outputDefaultSchema=false --changeLogFile=update.xml --url=jdbc:postgresql:%DATABASE%:@localhost:5432: updateSql -Dschema=%DBSCHEMA% \> %DIFF\_SQL\_INTERNAL%  

I’ve placed liquibase-nochangelogupdate-1.0.jar to lib directory inside liquibase installation.  
  
Hope I didn’t forget some step to activate the extension?  
  
Thank You  
  
Trigve

---

<div class="post-metadata">

**Author:** ![nvoxland](https://avatars.discourse-cdn.com/v4/letter/n/87869e/32.png) [@nvoxland](https://forum.liquibase.org/u/nvoxland)\
**Post date:** [August 8, 2013, 10:57pm UTC](https://forum.liquibase.org/t/do-not-include-create-or-insert-into-databasechangelog-table-when-using-updatesql-goal-with-maven/2671/6 "2013-08-08T22:57:00Z")

</div>

I think I see the problem. I had added a liquibase.ext.nochangelogupdate.enabled property to control enabling the extension but then was not handling the case where no property was specified (it was defaulting to not enabled).

I pushed out a 1.1 release that should fix the problem.

Nathan

---

<div class="post-metadata">

**Author:** ![Guest](https://avatars.discourse-cdn.com/v4/letter/g/8dc957/32.png) [@Guest](https://forum.liquibase.org/u/Guest)\
**Post date:** [August 8, 2013, 10:57pm UTC](https://forum.liquibase.org/t/do-not-include-create-or-insert-into-databasechangelog-table-when-using-updatesql-goal-with-maven/2671/7 "2013-08-08T22:57:00Z")

</div>

Thanks for looking it. I don’t want to sound rude but do you have the build (.jar) of the new version by any chance? Because I don’t have environment set up for building liquibase and plugins.  
  
Thank You  
  
Trigve

---

<div class="post-metadata">

**Author:** ![nvoxland](https://avatars.discourse-cdn.com/v4/letter/n/87869e/32.png) [@nvoxland](https://forum.liquibase.org/u/nvoxland)\
**Post date:** [August 8, 2013, 10:57pm UTC](https://forum.liquibase.org/t/do-not-include-create-or-insert-into-databasechangelog-table-when-using-updatesql-goal-with-maven/2671/8 "2013-08-08T22:57:00Z")

</div>

Yes, I did. It is &nbsp;at&nbsp;[https://github.com/liquibase/liquibase-nochangelogupdate/releases](https://github.com/liquibase/liquibase-nochangelogupdate/releases)

Nathan

---

<div class="post-metadata">

**Author:** ![Guest](https://avatars.discourse-cdn.com/v4/letter/g/8dc957/32.png) [@Guest](https://forum.liquibase.org/u/Guest)\
**Post date:** [August 8, 2013, 10:57pm UTC](https://forum.liquibase.org/t/do-not-include-create-or-insert-into-databasechangelog-table-when-using-updatesql-goal-with-maven/2671/9 "2013-08-08T22:57:00Z")

</div>

Hmm I see there .jar for version 1.0 only. And using diff there isn’t any difference to the previous one. Or did I miss something?  
  
Thank You  
  
Trigve

---

<div class="post-metadata">

**Author:** ![Guest](https://avatars.discourse-cdn.com/v4/letter/g/8dc957/32.png) [@Guest](https://forum.liquibase.org/u/Guest)\
**Post date:** [August 8, 2013, 10:57pm UTC](https://forum.liquibase.org/t/do-not-include-create-or-insert-into-databasechangelog-table-when-using-updatesql-goal-with-maven/2671/10 "2013-08-08T22:57:00Z")

</div>

Thanks for the .jar upload. It worked but I’ve got the problem with this system property:

1. liquibase.ext.nochangelogupdate.enabled

Because it is system property I don’t know how to set it (as command line argument) to affect only some instances of liquibase. Because what I found on the net, the one possibility is to use -DXXX=value as “java” command line argument and when I set it in liquibase.bat it affects all instances of course. But I need to selectively turn it off/on in my workflow. So could I somehow set the system parameter through the liquibase command options? Or through some environment variables? Becuase AFAIK the liquibase’s “-D” param option is only local to liquibase.  
  
Thank You  
  
Trigve

---

<div class="post-metadata">

**Author:** ![Guest](https://avatars.discourse-cdn.com/v4/letter/g/8dc957/32.png) [@Guest](https://forum.liquibase.org/u/Guest)\
**Post date:** [August 8, 2013, 10:57pm UTC](https://forum.liquibase.org/t/do-not-include-create-or-insert-into-databasechangelog-table-when-using-updatesql-goal-with-maven/2671/11 "2013-08-08T22:57:00Z")

</div>

After the testing and tweaking my scripts it looks like all is working fine.  
  
Can I somehow support the project through paypal?  
  
Thanks a lot!  
  
Trigve

---

<div class="post-metadata">

**Author:** ![nvoxland](https://avatars.discourse-cdn.com/v4/letter/n/87869e/32.png) [@nvoxland](https://forum.liquibase.org/u/nvoxland)\
**Post date:** [August 8, 2013, 10:57pm UTC](https://forum.liquibase.org/t/do-not-include-create-or-insert-into-databasechangelog-table-when-using-updatesql-goal-with-maven/2671/12 "2013-08-08T22:57:00Z")

</div>

[https://github.com/liquibase/liquibase-nochangelogupdate/releases/tag/liquibase-nochangelogupdate-1.1](https://github.com/liquibase/liquibase-nochangelogupdate/releases/tag/liquibase-nochangelogupdate-1.1)&nbsp;is the 1.1. release. It should be on the releases page, although it looks like I had forgot to attach the .jar file (still getting used to the github release process).

Nathan

---

<div class="post-metadata">

**Author:** ![nvoxland](https://avatars.discourse-cdn.com/v4/letter/n/87869e/32.png) [@nvoxland](https://forum.liquibase.org/u/nvoxland)\
**Post date:** [August 8, 2013, 10:57pm UTC](https://forum.liquibase.org/t/do-not-include-create-or-insert-into-databasechangelog-table-when-using-updatesql-goal-with-maven/2671/13 "2013-08-08T22:57:00Z")

</div>

Through the command line you need to specify -Dliquibase.ext.nochangelogupdate.enabled=[true|false] as a java param.&nbsp;

Looking at liquibase.bat, it looks like it is not respecting the JAVA\_OPTS environment variable like it should. I put in a fix for 3.0.6, but locally you can change the “set JAVA\_OPTS=” line to “IF NOT DEFINED JAVA\_OPTS set JAVA\_OPTS=” and then set the JAVA\_OPTS environment variable before running liquibase.

Nathan

---

<div class="post-metadata">

**Author:** ![nvoxland](https://avatars.discourse-cdn.com/v4/letter/n/87869e/32.png) [@nvoxland](https://forum.liquibase.org/u/nvoxland)\
**Post date:** [August 8, 2013, 10:57pm UTC](https://forum.liquibase.org/t/do-not-include-create-or-insert-into-databasechangelog-table-when-using-updatesql-goal-with-maven/2671/14 "2013-08-08T22:57:00Z")

</div>

Good to hear it’s working for you.&nbsp;

If you’d like to donate, there is a link on the sourceforge page&nbsp;[http://sourceforge.net/projects/liquibase/](http://sourceforge.net/projects/liquibase/)&nbsp;

that leads to&nbsp;[https://www.paypal.com/us/cgi-bin/webscr?cmd=\_flow&SESSION=5be3NXFOVTNYzW1sqYyeD-WAFJ-LL-1Dmf7YhpeUcifjCyiVurO83eL\_aIi&dispatch=5885d80a13c0db1f8e263663d3faee8d0038486cd0d9a2f3f8e698d26650388a](https://www.paypal.com/us/cgi-bin/webscr?cmd=_flow&SESSION=5be3NXFOVTNYzW1sqYyeD-WAFJ-LL-1Dmf7YhpeUcifjCyiVurO83eL_aIi&dispatch=5885d80a13c0db1f8e263663d3faee8d0038486cd0d9a2f3f8e698d26650388a)

Donations of any type are always very appreciated.

Nathan
