Search within CMSBuilder by Date Range

5 posts by 2 authors in: Forums > CMS Builder
Last Post: August 25, 2010   (RSS)

By jtedescojam - August 25, 2010

When someone makes a donation to my client's website, their donation information is inserted into a backoffice table in the CMS (most importantly, I have them sorted by 'createdDate' so I know when the most recent donation occurred and the time it occured). When I go to the CMS, I have set up the search to search by donation type, credit card, etc... however I need to be able to search by date range, or at least by month.. is this possible?
John Tedesco

Creative Director



JAM Graphics

Re: [jtedescojam] Search within CMSBuilder by Date Range

By Chris - August 25, 2010

Hi jtedescojam,

Yes, this is possible. Go into the Section Editor for your section and click on the Searching tab at the top. Add these two lines, replacing your date field name with the example in red:

Date min|mydatefield|min
Date max|mydatefield|max


The only catch here is that you must supply a complete date (including a time.) For example, if you wanted to find all the donations from the start of 2010 to now, leave the max field blank and enter "2010-01-01 00:00:00" in the min field.

Does this help? Please let me know if you have any questions.
All the best,
Chris

Re: [chris] Search within CMSBuilder by Date Range

By jtedescojam - August 25, 2010

okay, not the greatest solution, but it's going to do the job. Problem is I have to teach the client the easiest way to remember how to write the query.. i.e. 2010-08-05 00:00:00

Would be great if we could get this in drop down format.

thanks for being prompt
John Tedesco

Creative Director



JAM Graphics

Re: [jtedescojam] Search within CMSBuilder by Date Range

By Chris - August 25, 2010

Hi jtedescojam,

We could build a nice date-input widget into CMS Builder for you through our consulting service. Please let me know if you're interested and I'll write you up a quote.
All the best,
Chris