Click here to Skip to main content
15,905,612 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hi Everyone,

I want to create a SQL-Server scalar function that copy a data into new temp table when delete from the main table is occurs

Thanks in advance..
Posted
Comments
Rahul JR 4-Dec-13 3:11am    
new Temp Table means studentcopy table and
main table means student table
skydger 4-Dec-13 3:42am    
Why to use scalar function instead of stored procedure? What are the arguments it must contain? What is the value the function should return? Please improve you question.
Rahul JR 4-Dec-13 4:35am    
thnks for replay but i want some think like whenever a delete from main table is occurs than that data should be copied into to copy table

1 solution

try Delete Trigger[^] and to know more read SQL server database Triggers[^].
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900