```
milovidov-desktop :) SELECT toString(toDateTime('-922337203.6854775808', 1))

SELECT toString(toDateTime('-922337203.6854775808', 1))

Query id: 3d51ba80-4993-4f64-b6ef-da0c0f1bdf43

┌─toString(toDateTime('-922337203.6854775808', 1))─┐
│ 2106-02-07 :rE:�.6                                │
└──────────────────────────────────────────────────┘
```
inline time_t fromDayNum(DayNum d) const { return lut[d].date; }
    inline time_t toDate(DayNum d) const { return lut[d].date; }
    inline unsigned toMonth(DayNum d) const { return lut[d].month; }
    inline unsigned toQuarter(DayNum d) const { return (lut[d].month - 1) / 3 + 1; }
    inline unsigned toYear(DayNum d) const { return lut[d].year; }
    inline unsigned toDayOfWeek(DayNum d) const { return lut[d].day_of_week; }
    inline unsigned toDayOfMonth(DayNum d) const { return lut[d].day_of_month; }
    inline unsigned toDayOfYear(DayNum d) const { return d + 1 - toFirstDayNumOfYear(d); }
    inline unsigned toDayOfYear(time_t t) const { return toDayOfYear(toDayNum(t)); }
    
    
    
    inline unsigned toRelativeWeekNum(DayNum d) const
    {
        
        return (d + 8 - toDayOfWeek(d)) / 7;
    }
    inline unsigned toRelativeWeekNum(time_t t) const