PL/SQL Like

The LIKE operator is used to search a string using the percent sign (‘%’) and the underscore (‘_’).

Course table

COURSE_IDNAMEDESCRIPTIONDURATIONPRICE
1SQL 1SQL course for beginners1 week10
2SQL 2SQL course for advanced2 week50
3HTML5Learn HTML 51 week10
4PHPPHP course4 week75
5CSSLearn CSS2 week20

Like example

 
SELECT * FROM course WHERE description LIKE 'Lea%';

Output

COURSE_IDNAMEDESCRIPTIONDURATIONPRICE
3HTML5Learn HTML 51 week10
5CSSLearn CSS2 week20
 
SELECT * FROM course WHERE description LIKE '%course%';

Output

COURSE_IDNAMEDESCRIPTIONDURATIONPRICE
1SQL 1SQL course for beginners1 week10
2SQL 2SQL course for advanced2 week50
4PHPPHP course4 week75
 
SELECT * FROM course WHERE duration LIKE '%ek';

Output

COURSE_IDNAMEDESCRIPTIONDURATIONPRICE
1SQL 1SQL course for beginners1 week10
3HTML5Learn HTML 51 week10