1
Answer

How to write stored proc. search record using Like quer by initial charecter

sagar Bhosale

sagar Bhosale

13y
1.7k
1
Hi frends,
How to write stored proc.  search record using Like quer  by initial charecter

my stored procc is  i want to select  S_Name from SCHEMEDETAIL  by like query

set

set

ANSI_NULLS ON QUOTED_IDENTIFIER ON

go

-- =============================================

-- Author: <Author,,Name>

-- Create date: <Create Date,,>

-- Description: <Description,,>

-- =============================================

ALTER


PROCEDURE [dbo].[Get_SchemeRatings]-- Add the parameters for the stored procedure here

@AMC_CODE

varchar(100)

AS

BEGIN


-- SET NOCOUNT ON added to prevent extra result sets from


-- interfering with SELECT statements.


SET NOCOUNT ON;


-- Insert statements for procedure here





select sdt.S_NAME ,tsr.Ratingfrom SCHEME_DETAILS sdt left join T_SchemeRating tsr on sdt.SCHEMECODE = tsr.SCHEMECODEwhere convert (varchar(100),sdt.AMC_CODE)=@AMC_CODE

END

PLZ




Answers (1)