Multiple choice technology databases

what does the query select * from table_abc where column_xyz like '%oracle%'

  1. selects all the rows from the table having the column_xyz value starting with the word oracle

  2. selects all the rows from the table having the column_xyz value ending with the word oracle

  3. selects all the rows from the table having the column_xyz value containing the word oracle

  4. selects all the rows from the table having the column_xyz value not containing the word oracle

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

The % wildcard matches any sequence of characters (including zero characters). '%oracle%' means match any value that contains 'oracle' anywhere - before, after, or in between. It would match 'My oracle database', 'oracle', or '123oracle456'.

AI explanation

The LIKE '%oracle%' pattern uses the % wildcard on both sides of the search term, which matches any value that contains 'oracle' anywhere within it — at the start, middle, or end. A pattern anchored only at the start (oracle%) or end (%oracle) would restrict matches to those positions specifically, but with wildcards on both sides, the match is purely on containment.