I am new to SQL 2005 and have a question about Stored Procedures and have not been able to find a suitable answer to my question after trawling Google and Bing for days. I hope you can help.
I have a Visual Basic form and present my data in a DataGridView. My data table consists of 4 columns, ID, FirstName, LastName and DateofBirth. I can show data for a specific date of birth range using the following stored procedure:
ALTER PROCEDURE dbo.DateRange
SELECT FirstName, LastName, DateofBirth
WHERE DateofBirth BETWEEN '1-january-1952' AND '31-december-2012'
ORDER BY DateofBirth
/* SET NOCOUNT ON */
How do I use two datetimepickers on the VB form to replace the fixed dates in the WHERE clause in the code above?
Your help please.