-
Notifications
You must be signed in to change notification settings - Fork 35
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Search filter with datetime values #12
Comments
Hi! Just in case of eliminating potential misunderstandings, please provide the relevant parts of your code. |
I'm also experiencing this when using a MySQL database (5.6.12). It occurs due to a text query being done against a DATE field throwing the following warning at the database level:
Despite MySQL throwing this warning the query still executes correctly (see here for a bit more info: http://stackoverflow.com/questions/7038286/how-to-add-a-datetimefield-to-admin-changelists-search-fields), though if you have DEBUG=True, Django will treat it as an error. If you set DEBUG=False, the query should work. This has been reported as a bug: Finally, the relevant part of my model:
|
We actually fixed the bSearchable issue. The indexing is off in the current implantation. See this commit in our branch. commit ed487f8 |
Not sure if I am missing something really simple but it seems that I get a 500 error if the model returns a datetime value for the table. See error below. Any help will be appreciated.
Incorrect datetime value: '%De%' for column 'post_time' at row 1
The text was updated successfully, but these errors were encountered: