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 |
dim1962
Starting Member
1 Post |
Posted - 2010-10-20 : 15:33:58
|
Hi All, I never created a SQL trigger but I found it very practical.Please help me to learn it using this example:I have a database in SQL2000 with two tables A and B.The fields in table A are aID, a1, and a2.The fields in table B are bID, b1 and b2The field aID is link with field bID (one to one)I need a SQL trigger, which automatically update the field b1 with the same value which was entered for a1.In others words when a user insert or modify the value a1 from table A, automatically the field b1 from table B will have the same value as a1.Thanks a lot |
|
tkizer
Almighty SQL Goddess
38200 Posts |
|
GilaMonster
Master Smack Fu Yak Hacker
4507 Posts |
Posted - 2010-10-20 : 16:29:12
|
Homework?--Gail ShawSQL Server MVP |
|
|
tkizer
Almighty SQL Goddess
38200 Posts |
|
|
|
|