I'm trying to put together a shopping cart. As an extra feature I want to be able tu pull up all the orders for a certain date. To make it even better, I want to create a dropdown-list with the dates available in the DB. The problem is... there are several orders placed on each day, and I don't need all those dates.
I have this query: "SELECT date FROM orders"
That gives me a list that looks something like this:
2003-05-13
2003-05-13
2003-05-14
2003-05-14
etc...
How do I select only one date per day so the list might look like this instead?
2003-05-13
2003-05-14
etc...
I never know how many orders will be placed in one day.
Maybe this can be solved with PHP but I don't know how, so I'm trying mysql first.




Bookmarks