Include days in date calculation

15 posts by 2 authors in: Forums > CMS Builder
Last Post: January 13, 2015   (RSS)

By Jesus - January 13, 2015

Awesome, we're moving forward :)

I need a couple more things...

1. Is it possible to have the days_employed field as text using this format (as an example): 1 year, 2 months, 3 days or 2 years, 1 month, 1 day ?

2. Also, I've one extra field on my trabajadores table, that field name its Company, can I filer this results by company? (group by company).

Thanks in advance for your help and support!!! as always, 1st class!!!

Jesus

PS If I want to have this as a PDF, can I buy the Created PDF plugin in order to print this reports in a nice PDF?

By Jesus - January 13, 2015

Great and how about having the total days as: 

1 year, 2 months, 1 day

or

2 years, 1 month, 3 days

etc?

Please note the extra (s) for plural names (year(s), month(s) or day(s))

Thanks!

By claire - January 13, 2015

Sorry, that's what I mean - it's possible to do this kind of date calculation in MySQL, but it's very tricky. Again, see http://stackoverflow.com/questions/10765995/convert-days-to-years-months-days-in-mysql

It would be easier to export this to a spreadsheet and use that to do the extra formatting and saving as a PDF.

--------------------

Claire Ryan
interactivetools.com

Save time by getting our experts to help with your project.
http://www.interactivetools.com/consulting/

By Jesus - January 13, 2015

Oh, I think you mention the excel part because of my question for the PDF builder, sorry for the confusion.

I'm looking at the link you sent me right now. Lets see how it goes... Thanks