MySQL Forums
Forum List  »  Newbie

Between dates select statement
Posted by: Lovesalot Carluccio
Date: December 06, 2014 12:05PM

Hi,
Im trying to show transactions for a given week using the Select between dates statement.
I'm using the below statement;
SELECT TRANSACTION_NO
FROM RENTAL_DETAILS
WHERE RENT_DATE BETWEEN ‘2013-12-21’ AND ‘2013-12-27’;

and am getting an error message saying unknown column '2013' in where clause.

Any suggestions? I've tried using a Tp_DATE to format in YYYY-MM-DD and putting # before and after dates.

Any suggestions?????!!
Any help would be much appreciated!

Options: ReplyQuote


Subject
Written By
Posted
Between dates select statement
December 06, 2014 12:05PM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.