Home How can we extract the date .from the createCriteria in grails
Reply: 0

How can we extract the date .from the createCriteria in grails

dhS
1#
dhS Published in 2017-12-05 10:00:06Z
Date MonthStartDate = new Date() 

I need to fetch the date from datetime in Grails. Is there a way we can check the condituion of the CreateCriterai query with the date not with the datetime.

List listTransfer = Vehicle.createCriteria().list() {
    and {
        ge('startDate::date', MonthStartDate)
        le('endDate::date', MOnthStartDate)
    }
}
You need to login account before you can post.

About| Privacy statement| Terms of Service| Advertising| Contact us| Help| Sitemap|
Processed in 0.321337 second(s) , Gzip On .

© 2016 Powered by mzan.com design MATCHINFO