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.


How select the month of a date type ?

on 6/12/13, 12:37 PM 1,739 views

Hello everyone,

Do you know how to get the month (or the month and the year) of a date type field in xml ?

I would like to compare it like I compare the day :

<field name="domain">[('date_field','=', time.strftime('%Y-%m-%d'))]</field>

PS : sorry for my english :s



| 6 5 8
Delhi, India
Python OpenERP Developer http://in.linkedin.com/pub/sandeep-rana/3b/a16/786/
On 6/13/13, 3:42 AM

Hi There is nothing like this that you can select via month in a date field but you can make a dynamic domain

for that case you can split month and check it plz be sure dynamic domain are work on on change


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

0 follower(s)


Asked: 6/12/13, 12:37 PM
Seen: 1739 times
Last updated: 3/16/15, 8:10 AM