Solved

SSIS package for notification of changes

Posted on 2012-03-14
3
248 Views
Last Modified: 2012-03-21
I am trying to creat an ssis package that compares 2 data sets and updates the 2nd data set to match the first.  Anytime there is a change to data set #2 send and email notification with the results.  I have done a little bit with integration services in the past and have gotten the send mail with results from the query to work fine but I want to add few other steps and lessen the email by only sending when the data has changed. I am attaching a small flow diagram of what I am looking for.  Please let me know what compents to use while creating the ssis.
ssis-order-compare.docx
0
Comment
Question by:notasgoodasyou
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 
LVL 40

Expert Comment

by:lcohan
ID: 37722060
Did you considered Trigger(s) for this matter instead of SSIS? At the end, your Data sits in SQL database tables and that's where you could trace the "change" in real time by using INSERT, UPDATE, and DELETE triggers to do whatever comparison you need then send email or any other action.
0
 

Author Comment

by:notasgoodasyou
ID: 37722129
I will look into the triggers but I dont know how it will work with 2 different databases.  I am running a query against our main sap db to get a data set ( any orders that are past due that we have stock on ) Initially i put this into a seperate table then rerun the query comparing results.  I want this to run every 30 minutes and send an email anytime new stock is added for a past due order or a new order goes past due that we have stock for.  I will look into triggers and see what I find but any help is appreciated.
0
 
LVL 40

Accepted Solution

by:
lcohan earned 500 total points
ID: 37722178
"Initially i put this into a seperate table then rerun the query comparing results."

Are these two tables on the same SQL server in the same or separate DB's?
Im my opinion if you went this far already you could have a SQL Stored proc to compare the "seperate table" versus the "other" table or whatever data set (view?) you mean and if different send an email. Its easy to do all these from SQL code inside a stored proc - right?
Then all you need is a scheduled job to run every 30 minutes or so to
1. truncate/populate that "seperate table " from SAP db.
2. run this SQL stored proc to compare the 2 data sets and if different send the email.
0

Featured Post

Free eBook: Backup on AWS

Everything you need to know about backup and disaster recovery with AWS, for FREE!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
sql server connection string in config file 4 41
SQL syntax for max(date) 3 39
Using rowversion for incremental load of datawarehouse. 12 35
sql server query 9 27
This article explains how to reset the password of the sa account on a Microsoft SQL Server.  The steps in this article work in SQL 2005, 2008, 2008 R2, 2012, 2014 and 2016.
In the first part of this tutorial we will cover the prerequisites for installing SQL Server vNext on Linux.
Via a live example, show how to extract information from SQL Server on Database, Connection and Server properties
Via a live example, show how to shrink a transaction log file down to a reasonable size.

739 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question