Wrox Programmer Forums
|
BOOK: ASP.NET Website Programming Problem-Design-Solution
This is the forum to discuss the Wrox book ASP.NET Website Programming: Problem - Design - Solution, Visual Basic .NET Edition by Marco Bellinaso, Kevin Hoffman; ISBN: 9780764543869
Welcome to the p2p.wrox.com Forums.

You are currently viewing the BOOK: ASP.NET Website Programming Problem-Design-Solution section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old February 24th, 2007, 05:44 AM
Registered User
 
Join Date: Feb 2007
Posts: 5
Thanks: 0
Thanked 0 Times in 0 Posts
Default problem in trigger of chapter 6

The trigger shown below is used to set the user id =null so that we can update the UserID to Null value and rest of the corresponding feilds of User should be retain in database,but i got stucked in trigger u have written,why u used [u]deleted</u> in sub query

CREATE TRIGGER SetNewsAuthoeToNull ON [dbo].[Accounts_User]
FOR DELETE
AS
UPDATE News_News
SET UserID= NULL
WHERE UserID= (SELECT UserID FROM [u]Deleted</u>)




bel-india.com
 
Old February 26th, 2007, 11:45 PM
Friend of Wrox
 
Join Date: Jun 2003
Posts: 917
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Deleted refers to the record that is being deleted in this operation.






Similar Threads
Thread Thread Starter Forum Replies Last Post
Problem with Trigger program on an AS400 tattoo Other Programming Languages 0 June 20th, 2008 11:58 AM
Trigger problem kitkits SQL Server 2000 2 May 20th, 2005 09:17 AM
stored procedure problem with trigger helkayal SQL Server 2000 5 February 22nd, 2005 12:59 AM
Problem with update trigger gbrown SQL Language 2 September 4th, 2004 12:33 PM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.