Skip to main contentSkip to solution

What is the meaning of clause LIKE '7%7' in the context of SQL?

Solution

✅ Correct Option: 1

In the SQL LIKE operator, % stands for any number of characters, including zero characters. So '7%7' matches any value that starts with 7 and ends with 7, such as 77, 707 or 7abc7.


Option 4: this confuses % with _. The underscore matches exactly one character, so '7_7' would give exactly three characters.

Remember: % means zero or more characters, and _ means exactly one character.

Keyboard Shortcuts

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