# Extending Add|DropForeignKeyConstraintChange & Add|DropForeignKeyConstraintStmt

**URL:** <https://forum.liquibase.org/t/extending-add-dropforeignkeyconstraintchange-add-dropforeignkeyconstraintstmt/313>\
**Category:** General Discussion\
**Created:** [October 21, 2009, 6:02pm UTC](https://forum.liquibase.org/t/extending-add-dropforeignkeyconstraintchange-add-dropforeignkeyconstraintstmt/313 "2009-10-21T18:02:00Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![bradley\_lb](https://avatars.discourse-cdn.com/v4/letter/b/7feea3/32.png) [@bradley\_lb](https://forum.liquibase.org/u/bradley_lb)\
**Post date:** [October 21, 2009, 6:02pm UTC](https://forum.liquibase.org/t/extending-add-dropforeignkeyconstraintchange-add-dropforeignkeyconstraintstmt/313/1 "2009-10-21T18:02:00Z")

</div>

I’m trying to modify the the Add/DropForeignKeyConstraintChange classes for SQL Server to add cascading referential integrity (e.g. ON DELETE SET NULL) to the referenced table as a Trigger instead of as part of the constraint as per the discussion in my [previous thread](http://liquibase.org/forum/index.php?topic=155.0). Is it possible to extend these classes in 1.9.5 and supply my sub-classes of these to the Liquibase change factory without modifying the Liquibase source and having to compile it myself? If not, is it possible to do this in 2.0? Should I consider trying this using the RC version of 2.0?

Thanks!

---

<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:** [October 21, 2009, 6:02pm UTC](https://forum.liquibase.org/t/extending-add-dropforeignkeyconstraintchange-add-dropforeignkeyconstraintstmt/313/2 "2009-10-21T18:02:00Z")

</div>

I answered you question at [http://liquibase.org/forum/index.php?topic=155.0.&nbsp;](http://liquibase.org/forum/index.php?topic=155.0.%C2%A0) Liquibase 2.0 is definitely the way to go.

I assume you found it, but in case others have the same question…

Let me know what problems you run into so I can better improve the documentation

Nathan
