Multiple choice technology programming languages

For which action can you use the TO_DATE function?

  1. Convert any date literal to a date

  2. Convert any numeric literal to a date

  3. Convert any character literal to a date

  4. Convert any date to a character literal

  5. Format ’10-JAN-99’ to ‘January 10 1999’

Reveal answer Fill a bubble to check yourself
C Correct answer
Explanation

TO_DATE converts character strings to date values in SQL. It parses a character literal using a format mask to produce a DATE type. Option A is incorrect because date literals are already dates. Option B is wrong because numeric literals cannot be directly converted to dates without additional context. Option D describes TO_CHAR, not TO_DATE. Option E also describes formatting (TO_CHAR), not type conversion.