.NET Tutorials, Forums, Interview Questions And Answers
Welcome :Guest
 
Sign In
Register
 
Win Surprise Gifts!!!
Congratulations!!!


Top 5 Contributors of the Month
david stephan

Home >> Forum >> Sql Server >> Post New QuestionBookmark and Share Subscribe to Forum

How to know user name who have update table using SQL Server

Posted By: kamlesh     Posted Date: November 04, 2011    Points:5   Category :Sql Server
Hi.
i have one database and which is having multiple users, and suppose there is one table (xyz) , suppose any one user added any column in that table so ,how to know which user (user name) has added the one more column to that table.

Responses
Author: Akhil Raj       [Moderator]      
Posted Date: November 06, 2011     Points: 20   

read the following articles. This may help you

http://weblogs.asp.net/jgalloway/archive/2008/01/27/adding-simple-trigger-based-auditing-to-your-sql-server-database.aspx
http://blogs.technet.com/b/josebda/archive/2009/03/24/sql-server-2008-change-tracking-ct-and-change-data-capture-cdc.aspx
http://stackoverflow.com/questions/2243917/sql-server-2008-where-is-the-change-tracking-table-stored

Author: kamlesh             
Posted Date: November 09, 2011     Points: 20   

if (Convert.ToDouble(textBox1.Text) % 100 == 0)
{
if (Convert.ToInt64(textBox1.Text) == 0)
{
MessageBox.Show("Please enter Valid Money!!");
}
else
{
MessageBox.Show("Sucessl!!");
}
}
else
{
MessageBox.Show("Please enter Valid Money!!");
textBox1.Text = "";
return;
}

Thanks And Regards.
Kamlesh Nikam
Author: Maverick             
Posted Date: November 18, 2011     Points: 20   

Hello,

You can have an insert upadate and delete trigger on that table

Thanks,
Maverick


Post Reply

You must Sign In To post reply
 
 
Find more Forum Questions on C#, ASP.Net, Vb.Net, SQL Server and more Here
Quick Links For Forum Categories:
ASP.NetWindows Application  .NET Framework  C#  VB.Net  ADO.Net  
Sql Server  SharePoint  OOPs  SilverlightIISJQuery
JavaScript/VBScriptBiztalkWPFPatten/PracticesWCFOthers
www.DotNetSpark.comUnAnsweredAll

Hall of Fame    Twitter   Terms of Service    Privacy Policy    Contact Us    Archives   Tell A Friend