Database Insert from DMX Repeat

If you are referring to the code i provided a few weeks back:

Your expression is not correct.
It should be: query.month.monthDays() and not query.month.monthDays().daysInMonth

check my answer in the linked topic again.