Odoo Help


This community is for beginners and experts willing to share their Odoo knowledge. It's not a forum to discuss ideas, but a knowledge base of questions and their answers.


calculation date

on 12/17/14, 11:58 PM 524 views

I am newbie in odoo 8 , I add a date field entry and exit date and how to calculate the date of entry and exit dates

On 12/18/14, 2:42 AM

Mr.achuthan I am still confused with answer , Mr.achuthan could give a few examples of the answers above



| 5 3 6
Jakarta, Indonesia
On 12/18/14, 12:11 AM

You use normal python library to do date calculation.  There are many python datetime libraries out there, but I would recommend that you use datetime with some improvement from dateutil if necessary.


Atchuthan - Technical Consultant, Sodexis Inc

--Atchuthan - Technical Consultant, Sodexis Inc--
| 5 3 8
Puducherry, India
--Atchuthan - Technical Consultant, Sodexis Inc--
Passionate coder in Python/Odoo(formerly known as OpenERP).

Contact me via GMail: atchuthantu@gmail.com via Skype: atchuthan_skype
via Linkedin: http://in.linkedin.com/in/atchuthantu
Atchuthan - Technical Consultant, Sodexis Inc
On 12/18/14, 12:43 AM

d_frm_obj = datetime.strptime(entry_date, DEFAULT_SERVER_DATETIME_FORMAT)
d_to_obj = datetime.strptime(exit date, DEFAULT_SERVER_DATETIME_FORMAT)
diff = d_to_obj - d_frm_obj
print diff.days  //provides days


Your Answer

Please try to give a substantial answer. If you wanted to comment on the question or answer, just use the commenting tool. Please remember that you can always revise your answers - no need to answer the same question twice. Also, please don't forget to vote - it really helps to select the best questions and answers!

About This Community

This community is for professionals and enthusiasts of our products and services. Read Guidelines

Question tools

1 follower(s)


Asked: 12/17/14, 11:58 PM
Seen: 524 times
Last updated: 3/16/15, 8:10 AM