Skip to main contentSkip to solution

State the output of the following query:

SELECT MOD(DAY(“2003-03-24”),3);

Solution

✅ Correct Option: 3

DAY() returns the day of the month from a date, so DAY(2003-03-24)=24\text{DAY}(2003\text{-}03\text{-}24) = 24.

MOD(a, b) returns the remainder when aa is divided by bb.

MOD(24,3)=24−3×8=0\text{MOD}(24, 3) = 24 - 3 \times 8 = \boxed{0}

Keyboard Shortcuts

  • Left arrow: Previous question
  • Right arrow: Next question
  • S key: Jump to solution
  • Q key: Jump to question