AllRounder.ai
Chapters in this course

Enrol to start learning

Reading is open to everyone. Enrolling is free, and it is what unlocks the audio lessons, practice tests and progress tracking.

Enrol free

12.2.6. LIKE – Pattern Matching

  • This section

    Practice test

    11 questions on this section. Wrong answers show you what to read again.

    Sign up to take it
  • Whole chapter

    Revision test

    Mixed questions from across the chapter. Your answers get marked.

    Sign up to take it
  • Quick

    Flashcard drill

    3 cards from this lesson. Good the night before a test.

Try these first

  1. 1.

    Write a SQL query to find users with emails that end with '@yahoo.com'.

    Hint

    Use the wildcard '%' before '@yahoo.com'.

  2. 2.

    How would you find all products that start with 'Electro'?

    Hint

    Remember to use the wildcard '%' at the end.

  3. 3.

    What does the LIKE operator do in SQL?

    • A. Deletes records
    • B. Searches for a specified pattern
    • C. Updates records
    Hint

    Think about what type of operation you perform with `LIKE`.

  4. 4.

    True or False: The percent sign (%) in a LIKE clause can only appear at the end of the pattern.

    • True
    • False
    Hint

    Consider how wildcards can be used in different placements.

  5. 5.

    You are tasked with writing a SQL query that catches all email addresses beginning with 'info' and ending with a domain, ensuring both conditions are met.

    Hint

    Consider how to just capture valid domain emails.

  6. 6.

    Design a query to fetch all phone numbers that contain the digit '5' anywhere in them and end with '7'.

    Hint

    Utilize the '%' wildcard effectively before '5' and place '7' at the end.

Exercises

Total Questions

2

Estimated Time

4 min

Passing Score

70%

Instructions

  • Read each question carefully
  • You can use hints if you need help
  • Complete all questions before submitting

4 more questions available

Enrol free

Quiz

Total Questions

2

Estimated Time

4 min

Passing Score

70%

Instructions

  • Read each question carefully
  • You can use hints if you need help
  • Complete all questions before submitting

1 more question available

Enrol free

Challenge Problems

Total Questions

2

Estimated Time

4 min

Passing Score

70%

Instructions

  • Read each question carefully
  • You can use hints if you need help
  • Complete all questions before submitting