Hi All,
This is going to sound rather silly I fear.
I have just started using stored procedures and am trying to select a number of records with a start date less than 21/03/03.
If I link the table I am running the stored procedure on to access and run a query I get results no problem.
The stored procedure however returns nothing.
I have stripped the conditions and joins out and am left with this:
SELECT *
FROM myTable
WHERE myField <21/03/03
I have also tried
SELECT *
FROM myTable
WHERE convert(smalldatetime,myField,103) <21/03/03
etc, etc.
Can some one please tell me what is wrong.
I know it is a basic question but it is driving me mad.
Thank you all.
This is going to sound rather silly I fear.
I have just started using stored procedures and am trying to select a number of records with a start date less than 21/03/03.
If I link the table I am running the stored procedure on to access and run a query I get results no problem.
The stored procedure however returns nothing.
I have stripped the conditions and joins out and am left with this:
SELECT *
FROM myTable
WHERE myField <21/03/03
I have also tried
SELECT *
FROM myTable
WHERE convert(smalldatetime,myField,103) <21/03/03
etc, etc.
Can some one please tell me what is wrong.
I know it is a basic question but it is driving me mad.
Thank you all.