USE [eRaceClub] GO /****** Object: StoredProcedure [dbo].[LookupProductsByCategoryId] Script Date: 02/13/2008 18:46:36 ******/ SET ANSI_NULLS ON GO SET QUOTED_IDENTIFIER ON GO ---------------------- -- Product Procedures ---------------------- -- LookupProductsByCategoryId ALTER PROCEDURE [dbo].[LookupProductsByCategoryId] @CategoryId int AS BEGIN IF @CategoryId IS NULL raiserror('LookupProductsByCategoryId - Must enter Category Id', 16, 1) ELSE SELECT ProductId, Description, SalesPrice, QuantityOnHand FROM Product WHERE CategoryId = @CategoryId -- END IF END RETURN