trigger example???

Please support our ASP.NET advertiser: Intel Parallel Studio Home
Reply

Join Date: Nov 2007
Posts: 28
Reputation: u4umang2001 is an unknown quantity at this point 
Solved Threads: 0
u4umang2001's Avatar
u4umang2001 u4umang2001 is offline Offline
Light Poster

trigger example???

 
0
  #1
Feb 6th, 2008
Hi

i m working with ASP.Net, C#

i need to have an example of trigger

how to call it from C#, and how to execute???
Thanks & Regards
Umang
Reply With Quote Quick reply to this message  
Join Date: Jan 2008
Posts: 2,052
Reputation: serkan sendur is a glorious beacon of light serkan sendur is a glorious beacon of light serkan sendur is a glorious beacon of light serkan sendur is a glorious beacon of light serkan sendur is a glorious beacon of light serkan sendur is a glorious beacon of light 
Solved Threads: 118
Featured Poster
serkan sendur serkan sendur is offline Offline
Postaholic

Re: trigger example???

 
0
  #2
Feb 6th, 2008
what kind of trigger do you mean?
Due to lack of freedom of speech, i no longer post on this website.
Reply With Quote Quick reply to this message  
Join Date: Nov 2007
Posts: 28
Reputation: u4umang2001 is an unknown quantity at this point 
Solved Threads: 0
u4umang2001's Avatar
u4umang2001 u4umang2001 is offline Offline
Light Poster

Re: trigger example???

 
0
  #3
Feb 6th, 2008
sql trigger
Thanks & Regards
Umang
Reply With Quote Quick reply to this message  
Join Date: Jan 2008
Posts: 2,052
Reputation: serkan sendur is a glorious beacon of light serkan sendur is a glorious beacon of light serkan sendur is a glorious beacon of light serkan sendur is a glorious beacon of light serkan sendur is a glorious beacon of light serkan sendur is a glorious beacon of light 
Solved Threads: 118
Featured Poster
serkan sendur serkan sendur is offline Offline
Postaholic

Re: trigger example???

 
0
  #4
Feb 6th, 2008
you dont call a trigger from asp.net, sql trigger is constructed in sql server and it listens for the changes in the specified table(updates, deletes, inserts) .If specified table is modified, then trigger do some changes according to what it is told to.
take this for an example : you have related tables, when the parent table row is deleted you want to delete all the childrows of that parent row, then you specify a trigger for the parent table and tell it to delete all the records in the corresponding child table when a row deleted from the parent table.
Due to lack of freedom of speech, i no longer post on this website.
Reply With Quote Quick reply to this message  
Join Date: Sep 2007
Posts: 1,080
Reputation: SheSaidImaPregy is an unknown quantity at this point 
Solved Threads: 68
SheSaidImaPregy SheSaidImaPregy is offline Offline
Veteran Poster

Re: trigger example???

 
0
  #5
Feb 6th, 2008
Read up on Primary keys and Foreign keys. This is how you relate the tables together with a trigger to delete all childrows or update all childrows when the parent row is modified or deleted. This is all done on the server, so if you wish for an explanation of triggers, please visit the MS SQL portion of this site at: http://www.daniweb.com/forums/forum127.html
Reply With Quote Quick reply to this message  
Join Date: Feb 2008
Posts: 30
Reputation: dilipv is an unknown quantity at this point 
Solved Threads: 4
dilipv dilipv is offline Offline
Light Poster

Re: trigger example???

 
0
  #6
Feb 14th, 2008
Originally Posted by u4umang2001 View Post
Hi

i m working with ASP.Net, C#

i need to have an example of trigger

how to call it from C#, and how to execute???
Hi u4umang2001,
Just check this link, which contains good article. Hope this will help you.

http://www.c-sharpcorner.com/UploadF...ingCSharp.aspx

Thanks & Regards
Dilip Kumar Vishwakarma
Programmer
.Net Consulting
Reply With Quote Quick reply to this message  
Reply

This thread is more than three months old.
Perhaps start a new thread instead?
Message:


Thread Tools Search this Thread



About Us | Contact Us | Advertise | DaniWeb | Acceptable Use Policy | RSS Feed

©2003 - 2009 DaniWeb® LLC