usp_GetProductEditionByLicense.sql 490 Bytes
 
CREATE PROCEDURE [dbo].[usp_GetProductEditionByLicense]   
 -- Add the parameters for the stored procedure here  
 @iLicenseId int
AS  
BEGIN  
 -- SET NOCOUNT ON added to prevent extra result sets from  
 -- interfering with SELECT statements.  
 SET NOCOUNT ON;  
	 SELECT     Edition.Id, Edition.Title, Edition.IsActive, Edition.Priority
	 FROM  Edition
	 INNER JOIN LicenseToEdition ON  Edition.Id = LicenseToEdition.EditionId
	 WHERE  LicenseToEdition.LicenseId =@iLicenseId
END