For SQL Server:
SELECT [ID],[RollNo],[Name],[Address],[Telephone],AdmissionDate]
FROM [dbo].[Students]
where
(DATEPART(DAY,AdmissionDate)= '31' ) and DATEPART(MONTH,AdmissionDate)= '08' and DATEPART(YEAR,AdmissionDate)= '2014'
order by ID desc
SELECT [ID],[RollNo],[Name],[Address],[Telephone],AdmissionDate]
FROM [dbo].[Students]
where
(DATEPART(DAY,AdmissionDate)= '31' ) and DATEPART(MONTH,AdmissionDate)= '08' and DATEPART(YEAR,AdmissionDate)= '2014'
order by ID desc
No comments:
Post a Comment