Veeam® is happy to provide the Microsoft community with a study guide prepared by MVP and MCT, Orin Thomas. This guide will take you through each of the exam objectives, helping you to prepare for and pass the examination.
ALTER PROCEDURE [dbo].[web_search_getProducts] @searchText as nvarchar (20) = NULL, @brand as nvarchar (20) = NULL, @deptID as int = 0, @catID as int = 0, @filter1 as int = 0, @PageNo as integer = 1, @PageRecs as integer = 50, @OrdType as integer = 0, @custID as int = 0 AS WITH results AS ( SELECT rowNo = ROW_NUMBER() OVER(ORDER BY case @OrdType when 0 then i.MSRP end Desc, case @OrdType when 1 then i.MSRP end Asc, case @OrdType when 2 then i.subdescription1 end Asc, case @OrdType when 3 then i.subdescription1 end desc), i.ID AS itemID, i.Description AS itemDesc, i.ItemLookupCode, c.ID AS catID, c.Name AS catName, d.ID AS deptID, d.Name AS deptNAme, ie.Description, ie.Short_Desc, ie.Video, ie.Image, ie.Path, i.Quantity, i.MSRP, i.SubDescription1 as brand, a.id as AttributeID, a.name as Attribute, iav.id as AttributeValueID, iav.value as AttributeValue FROM dbo.Item i INNER JOIN dbo.Category c ON i.CategoryID = c.ID INNER JOIN dbo.Department d ON c.DepartmentID = d.ID INNER JOIN dbo.Item_Extended ie ON i.ID = ie.RMS_ID LEFT JOIN dbo.Items_AttributeValues iavs ON iavs.itemID = i.ID LEFT JOIN dbo.Item_Attribute_Value iav on iav.id = iavs.attributeValueID LEFT JOIN dbo.Item_Attribute a on a.id = iav.attributeID -- filtering based on fields WHERE (i.Inactive = 0) AND (@brand IS NULL OR i.Subdescription1 LIKE '%' + @brand + '%') AND (@deptID = 0 OR d.ID=@deptID) AND (@catID = 0 OR c.ID=@catID) AND ((@searchText IS NULL OR i.Description LIKE '%' + @searchText + '%') OR (@searchText IS NULL OR i.ExtendedDescription LIKE '%' + @searchText + '%')) -- filter based on attribute value AND (@filter1 = 0 OR iav.id=@filter1) ) SELECT * FROM results WHERE rowNo between ((@PageNo-1)*@pagerecs)+1 and @PageNo*@pagerecs
Add your voice to the tech community where 5M+ people just like you are talking about what matters.
Join the community of 500,000 technology professionals and ask your questions.