Stored Procedure to find data between dates

Raj.Trivedi
Posted by Raj.Trivedi under Sql Server category on | Points: 40 | Views : 1129
Database Table

CREATE TABLE [dbo].[StudentAdmission](
[AdmissionNumber] [varchar](20) NULL,
[StudentName] [varchar](20) NULL,
[StudentRollNumber] [int] NULL,
[RegisteredDate] [datetime] NULL
) ON [PRIMARY]

GO

SET ANSI_PADDING OFF
GO

Stored Procedure
create proc GetDatabetweenDates
(
@FromDate datetime,
@todate datetime
)
as
begin
select * from StudentAdmission where RegisteredDate between @FromDate and @todate
end

Comments or Responses

Login to post response