c#


Filter Table Triggers when using SMO DependencyWalker


I have a database with numerous tables that I use the SMO DependencyTree and DependencyWalker to order them by dependencies and then script them out. However, there are two particular tables that have the following relationship:
CREATE TABLE Production_Events (
Event_Id int identity(1,1) NOT NULL,
Start_Time datetime NOT NULL,
End_Time datetime null
--... other columns
)
CREATE TABLE Production_Event_Data (
Production_Event_Data_Id int identity(1,1) NOT NULL,
Event_Id int NOT NULL, -- Foreign key to the above table
Variable_Id int NOT NULL, -- Foreign key to another table
Variable_Value varchar(25) NULL
--... other columns
)
The Production_Event table has a FOR INSERT trigger which populates the Production_Event_Data table with values that come from various sources when a new row is inserted in Production_Event.
If there is no trigger present on the Production_Event table, the DependencyWalker will properly order these tables for scripting by detecting the Foreign Key relationship between them. However, if the trigger is present, then DependencyWalker sees the trigger as a dependency and orders the tables incorrectly by putting the Production_Event_Data table before the Production_Events. Ultimately this will end with a Foreign Key Constraint error if you try to execute the script.
Is there a way to configure DependencyWalker to only account for table dependencies and NOT trigger dependencies?

Related Links

Get dynamically created checkbox value from Gridview | Asp.net
Parsing LuisResult to get JSON fields
Hosting Asp.Net Core within IIS 7
C# Sql Connection can not connect to server
Printing from WPF to a Laser Printer cuts off part of document
Hash Table to find the number that appears the most in a list
How to resize all elements in the form to different resolution C#
Telerik Kendo MVC Grid - Setting Custom Filtering
Set 1 field for all records to a given value using Entity Framework 6
Minimizing child modal form without minimizing main form and recover child modal form
Custom translation with ObjectContext.Translate
create unique project code in c#
Asp Net Core: Switch between Windows and User Authentication
Send email based on Request.QueryString parameters received
ASP.NET Core (.NET Framework) Which VS Project Type / NuGet Format?
ASP.NET gridview add dynamic filtering to the column

Categories

HOME
max
netty
ssh
jenkins-pipeline
openacc
snappy
skypedeveloper
jquery-plugins
okhttp3
bitbucket
crash
symfony-sonata
localhost
uml-designer
procmon
webpack-dev-server
subprocess
dcos
jcodemodel
elastalert
github-flavored-markdown
responsive
luis
ofbiz
orange
printf
audio-streaming
datazen-server
angular2-pipe
fastboot
pushbullet
quality-center
cloudformation
angular2-changedetection
ios-autolayout
visual-studio-debugging
minitest
geocomplete
asp.net-webhooks
cocoa-scripting
word-wrap
linkurious
contenteditable
taiga
infovis
hierarchical-clustering
jsfl
import.io
ng-class
audio-fingerprinting
vertex
android-vectordrawable
androiddesignsupport
reloaddata
msiexec
require-handlebars
weblogic-maven-plugin
laterjs
jmap
apache2-module
askbot
controlpanel
webservices-client
gitk
edgar
log4cxx
vspackage
cakephp-2.6
cl.exe
iphone-6
javadb
qf-test
api-eveonline
mvcgrid
django-tests
pthreads-win32
mixradio
mysql-error-1146
8-puzzle
sygic
pechkin
ironworker
ia-32
zend-db-table
typography
backbone-views
coinbase-php
gwt2
jquery-1.8
waveout
github-archive
advanceddatagrid
project-files
nsundomanager
wdm
backlight
gmagick
marathontesting
nyromodal
mysql-pconnect
pkcs#7
stackless

Resources

Database Users
RDBMS discuss
Database Dev&Adm
javascript
java
csharp
php
android
javascript
java
csharp
php
python
android
jquery
ruby
ios
html
Mobile App
Mobile App
Mobile App