Get Even More Visitors To Your Blog, Upgrade To A Business Listing >>

LIKE

When you don’t know what value you need to Search then you can use the like operator in where cluse.
Symbols with like.
(%) Represents any number of characters
(_) the underscore symbol represents a single character.
The search string is enclosed in single quotation marks.sql wildcard
Examples
Select Ename,job
From emp
Where ename like ‘c%’;
Ename      job
---------- ---------
Clark      manager


Select ename,job
From emp
Where ename like ‘s%’;
Ename      job
---------- ---------
Smith      clerk
Scott      analyst
Sql> select ename
  2  from emp
  3  where ename like '_a%';

Ename
----------
Ward
Martin
James
The result is a list of employee names .each name includes the Letter a as the second letter in the name.


This post first appeared on Oracle Sql Tutorials,oracle 10g Tutorial, please read the originial post: here

Share the post

LIKE

×

Subscribe to Oracle Sql Tutorials,oracle 10g Tutorial

Get updates delivered right to your inbox!

Thank you for your subscription

×