How do i make a Date type constraint in KoBoToolbox

Thanks for your advice. but now i have other question to asking you
A3. What year did you graduate (or complete) with this qualification?
A5. In what year did you start working in this facility?
If i want A5 equal or larger than A3 what is the formulas in xls form?

Hello,
add constraint to ${A5} >= ${A3} and a good constraint_message.
See also recent post:

You should use two date type questions here with appearance (XLS column) = year…

Side-note: Also, you may need also to take care in your questionnaire flow that both variables might be empty (for reality). Maybe you will need to add to the constraint … or ${A5} = ‘’ (for empty string)

2 Likes

Thanks let’s me try it.

1 Like

It not work. Any solution.

Hi @Ah_ly,

Would you mind trying out an example that has been discussed before (it should solve your issue):

Have a great day!

1 Like

Hello,
maybe datetime type would be the better solution for Ah_ly.
Best

1 Like

Thanks, it works now.

1 Like