Oracle Tutorial

Distinct Examples

Example 1

Select Distinct user_id, name
From users_log

Example 2

Select Distinct b.author, b.book_name
From books b
Where b.author = 'SMITH'
And book_name Like '%ORACLE%'



Example 3

Select avg(Distinct price)
From books
Where book_name Like = '%JAVA%';