How to take out all lines that are not between two dates?
For example, I have two columns in my database:
Date1 and Date2. I am putting in my input fields (field1 = 12/11/14 and field2 = 22/11/14). So I want to take all rows in the table that have a lower date than 12/11/14
and above 22/11/14
. What should my request look like?
I'll make my question clearer.
Here is my DB:
So, I put in a rent_date
customer who rents a car from 11/12/14
and will return it to 11/22/14
. There are 5 clients, and only one is renting a car between the points 11/12/14
and 11/22/14
so I want to select the other 4 clients who do not rent a car between these two dates. I hope I understand. :)
source to share