﻿<?xml version='1.0' encoding='UTF-8'?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/"><channel><title>SQLServerCentral / SQL Server 2008 / SQL Server Newbies  / Delete trigger with parameters from webform / Latest Posts</title><generator>InstantForum.NET v2.9.0</generator><description>SQLServerCentral</description><link>http://www.sqlservercentral.com/Forums/</link><webMaster>notifications@sqlservercentral.com</webMaster><lastBuildDate>Mon, 17 Jun 2013 23:13:16 GMT</lastBuildDate><ttl>20</ttl><item><title>Delete trigger with parameters from webform</title><link>http://www.sqlservercentral.com/Forums/Topic1428563-1292-1.aspx</link><description>I have a web form with a gridview of a sql table that will allow the user to delete a row.  This is a supervisory task that is necessary since updating the table would be a logistical nightmare.  I would like to use a delete trigger within SQL Server 2008 R2 that will move the information into a delete history table before it deletes the row.  The question that I have is I want to pass 3 parameters to the history table at the same time.  Also, in the delete triggers how do I identify fields that need to be inserted into the history table and how do I identify the parameters.  One parameter comes from a drop down list on the form.  The other two are current date and time which can be calculated either in the trigger or on the form.  I also need to pass the username which is cached using Windows Authentication on the form.  I have the form completed and the trigger started, but I am getting stuck on the insert syntax especially relating to the parameters.</description><pubDate>Fri, 08 Mar 2013 06:56:58 GMT</pubDate><dc:creator>vavfam 50321</dc:creator></item></channel></rss>