Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
| Author |
Topic |
|
mike123
Master Smack Fu Yak Hacker
1462 Posts |
Posted - 2009-09-03 : 06:41:36
|
| Hey Guys,trying to run the below query but get an error.. is there anyway I can do a DELETE based on a JOIN ?Thanks!Mike123CREATE PROCEDURE [dbo].[delete_assignment_item_designer] ( @designerID int, @itemCode varchar(6) )AS SET NOCOUNT ONDELETE FROM [dbo].[tblItemAssignments] IAJOIN tblOrderedItems OI on OI.itemID = IA.itemIDWHERE designerID = @designerID AND OI.itemCode = @itemCode GO |
|
|
YellowBug
Aged Yak Warrior
616 Posts |
Posted - 2009-09-03 : 06:48:18
|
| DELETE FROM [dbo].[tblItemAssignments]FROM [dbo].[tblItemAssignments] IAJOIN tblOrderedItems OI on OI.itemID = IA.itemIDWHERE designerID = @designerID AND OI.itemCode = @itemCode |
 |
|
|
|
|
|