Days between dates is a trivial problem - julday(date2) - julday(date1) - how is it possible to mess this up?