Date range in Rails -


i´m looking find "books" between specific dates.

i have variable publishdate , want books have publish date between dates, i´m not sure operator use.

i tought of it´s not working

@books = book.where(:e_release_date => 20141217 && :e_release_date <= 20141017) 

i'm assuming using activerecord. in activerecord can query between this:

@books = book.where(:e_release_date => 20141217..20141017) 

Comments

Popular posts from this blog

timeout - Handshake_timeout on RabbitMQ using python and pika from remote vm -

gcc - MinGW's ld cannot perform PE operations on non PE output file -

c# - Search and Add Comment with OpenXML for Word -