class Data(models.Model):
time = models.DateTimeField()
I have in my variable:
var = 2013-01-17 17:30
Data.objects.filter(time=var)
I need all Data from this day(2013-01-17 - without time)
How to do?
I had the same problem and fixed it simply by using models.DateField()
instead of models.DateTimeField()
.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With