Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
| Author |
Topic |
|
doran_doran
Posting Yak Master
179 Posts |
Posted - 2009-12-04 : 12:33:19
|
| Okay, I came to learn one of the database will not allow triggers to add. (luckily few of them will allow).Question is: I was using triggers on insert, update. How can I accomplish similar using stored procedure. and how is the scheduling is done (i mean how often the sp will kick in and how will it know the modification or insert)? |
|
|
tkizer
Almighty SQL Goddess
38200 Posts |
|
|
doran_doran
Posting Yak Master
179 Posts |
Posted - 2009-12-04 : 13:52:59
|
| 1. I cannot have triggers.2. Idea is if a record been added or update in one database's table (database1, table1) then it will add or update another database (database2, table2).3. My plan was to use trigger on database1, table1 but that option is not available.Now. given the fact above, what are my option? How can I achieve similar goal like triggers but using stored proc> |
 |
|
|
tkizer
Almighty SQL Goddess
38200 Posts |
Posted - 2009-12-04 : 14:00:11
|
| I don't think you understood my post. Where are you performing the data modifications for database1? From your application or stored procedure? Wherever it is, that's where you need to add code to include the data modifications for database2.Why don't you consider transactional replication instead?Tara KizerMicrosoft MVP for Windows Server System - SQL Serverhttp://weblogs.sqlteam.com/tarad/Subscribe to my blog"Let's begin with the premise that everything you've done up until this point is wrong." |
 |
|
|
doran_doran
Posting Yak Master
179 Posts |
Posted - 2009-12-04 : 15:29:14
|
| 1. Data modification happens at database1.2. There is no application that is tie to database1. (I mean there is but we are not touching the frontend). SO I am to use stored proc at database1 and there is no sp_send_dbmail for the database server. I am to send email notification as well on insert and update.3. Transactional replication sound good but complicated. Never heard or use that term. |
 |
|
|
tkizer
Almighty SQL Goddess
38200 Posts |
|
|
|
|
|