sai kotturu

sai kotturu

  • NA
  • 5
  • 7.1k

how to convert Stored procedure into Linq SELECT * FROM dbo.View_ProductVersie

Nov 19 2012 1:27 AM

ALTER

PROCEDURE [dbo].[ProductVersie_GetVersions]

(

@ProductId

)

INT = NULL

AS

BEGIN

SET

NOCOUNT ON




SELECT * FROM dbo.View_ProductVersieWHERE ( @ProductId IS NULL OR ProductId = @ProductId )




ORDER BY CASE WHEN IsStructuurProduct = 1 THEN 0 -- Leergangen



ProductId

Versie

END

ELSE 1END, , DESC

Answers (1)