Oracle sql practice exercises with solutions

preview_player
Показать описание
SQL Practical Interview question
Oracle sql practice exercise with solution
SQL questions for data analysis
SQL scenario based interview questions
Рекомендации по теме
Комментарии
Автор

This is one kind of social service... By giving your knowledge to others... Not a small thing.. I don't have a habit to commenting under videos but after watching more videos just wanted to appreciate you sir 🎉🎉🎉 you are doing social service like this hands of you SIVA garu

vineetadola
Автор

select * from (select S_NO, COL1, COL2, COL3, COL4, COL5 from sort_a2
where 'A'=
case
when col1='A' then col1
when col2='A' then col2
when col3='A' then col3
when col4='A' then col4
when col5='A' then col5
else null
end
);

Pmreedy
Автор

select * from tab where (case when col1 = 'A' then 'true' when col2 = 'A' then 'true' end) = 'true';

anujrana
Автор

your way of explanation and effort u put are most deserves everything

Chandrashekar-kzvc
Автор

hello siva, your videos are great help to us.i would be great if you share the scripts for creating and inserting the data so that we can try from our side do..let me know if ur scripts are available

fathimarizwana
Автор

Sir Please provide Blank-Padded and Nonpadded Comparison Semantics oracle sq, below are example Blank-Padded Nonpadded
'ac' > 'ab'

'ac' > 'ab'

'ab' > 'a '

'ab' > 'a '

'ab' > 'a'

'ab' > 'a'

'ab' = 'ab'

'ab' = 'ab'

'a ' = 'a'

'a ' > 'a'

Raghava
Автор

I had a question it was asked to me in an interview.If given a emp table where the columns are emp_id, emp_name, salary, manager_id then get no of repotees and name of repotee for each employee

aniketjagdale
Автор

Is the value blank or NULL, because Concatenating Null with a value gives null.

akshaynaik
Автор

select * from test1 where s_no in (
select decode(col1, 'A', S_NO, 0)+decode(col2, 'A', S_NO, 0)+decode(col3, 'A', S_NO, 0)+decode(col4, 'A', S_NO, 0)+decode(col5, 'A', S_NO, 0) from test1);

annu
Автор

GOOD.. But UNION ALL is not very efficient optimally speaking.. i like the IN solution

apamwamba
Автор

If we are using OR conditions or using the second method performance-wise there will not be any difference ryt ? Since oracle will be using same execution plan for both .

biostravelsspot
Автор

Could you attach the database demo to your exercises?

nguyenhuuthinhvnpl
Автор

Nice Siva, I am big fan of yours, couple of queries --

1. UNION ALL - In case table contains duplicates it will appear multiple times.
2. CONTATINATION or INSTR will work only when its just character A, if there are repetitive characters like CA, AB, even this will be fetched if our intent is to search for only A

Agree? - Correct me if i am wrong :)

vikram
Автор

Hi Siva,
Need a help, Can you please share us the complete datasets which will help us to practice with data. Thanks in advance.

ShanmugamChandran-zo
Автор

Hi Siva,

What if we have both upper and lower case A in our table
how can we write then ?

sai-ojkc
Автор

Sir what if we write
Select least(col1, col2, col3, col4, col5)
From tab1

SANKMADEIT
Автор

This is the easiest way:

select s_no from tab1
where instr(col1||col2||col3||col4||col5, 'A') > 0
order by s_no

harrykeshramma
Автор

Never thought we can write where clause like this
Where Value in (column names)

fkrockerzz
Автор

It is good one. Please post more scenarios

robertcrues
Автор

hello sir, i want to become an sql developer.i am in my final year.can u provide any guidance to how can i get a job in this domain.

akshaynimbhore
visit shbcf.ru