SlideShare a Scribd company logo
OPerators.pptx Best topics dbms.   Good one
OPerators.pptx Best topics dbms.   Good one
Operators in Oracle SQL
1. Arithmetic
2. Comparison
3. Logical
4. Bitwise
5. other operations
Operator Description Syntax Example Output
+ Addition
SELECT column1 +
column2 FROM
table;
SELECT 10 + 5
FROM dual;
15
- Subtraction
SELECT column1 -
column2 FROM
table;
SELECT 10 - 5
FROM dual;
5
*
Multiplicati
on
SELECT column1 *
column2 FROM
table;
SELECT 10 * 5
FROM dual;
50
/ Division
SELECT column1 /
column2 FROM
table;
SELECT 10 / 5
FROM dual;
2
MOD
Modulus
(Remainder)
SELECT MOD
(column1,
column2) FROM
table;
SELECT MOD (10,
3) FROM dual;
1
OPerators.pptx Best topics dbms.   Good one
OPerators.pptx Best topics dbms.   Good one
OPerators.pptx Best topics dbms.   Good one
OPerators.pptx Best topics dbms.   Good one
OPerators.pptx Best topics dbms.   Good one
OPerators.pptx Best topics dbms.   Good one
OPerators.pptx Best topics dbms.   Good one
Comparison Operators
OPerators.pptx Best topics dbms.   Good one
OPerators.pptx Best topics dbms.   Good one
OPerators.pptx Best topics dbms.   Good one
OPerators.pptx Best topics dbms.   Good one
OPerators.pptx Best topics dbms.   Good one
OPerators.pptx Best topics dbms.   Good one
OPerators.pptx Best topics dbms.   Good one
Logical Operators
Used to combine multiple conditions.
Operator Description Syntax
AND
Returns TRUE if both
conditions are true
SELECT * FROM employees
WHERE age > 30 AND
department = 'HR';
OR
Returns TRUE if at least one
condition is true
SELECT * FROM employees
WHERE age > 30 OR
department = 'HR';
NOT Negates a condition
SELECT * FROM employees
WHERE NOT department =
'HR';
DIFFERENCE BETWEEN != NOT
Concatenation Operator ||
concatenation operator (||) is used to combine two or
more strings into a single string.
OPerators.pptx Best topics dbms.   Good one
Set Operators
Used to combine the results of multiple SELECT queries.
Operator Description Syntax
UNION
Combines unique
records from both
queries
SELECT column1 FROM table1 UNION
SELECT column1 FROM table2;
UNION ALL
Combines all records
(including duplicates)
SELECT column1 FROM table1 UNION
ALL SELECT column1 FROM table2;
INTERSECT
Returns common
records from both
queries
SELECT column1 FROM table1
INTERSECT SELECT column1 FROM
table2;
MINUS
Returns records in first
query but not in second
SELECT column1 FROM table1 MINUS
SELECT column1 FROM table2;
OPerators.pptx Best topics dbms.   Good one
OPerators.pptx Best topics dbms.   Good one
UNION vs UNION ALL
If you want to include duplicate rows, use UNION ALL:
The INTERSECT operator in DBMS is used to return the common records
(intersection) from two or more SELECT queries. It only includes rows that
appear in both result sets.
OPerators.pptx Best topics dbms.   Good one
OPerators.pptx Best topics dbms.   Good one
OPerators.pptx Best topics dbms.   Good one
 Both queries must have the same number of columns and data types.
 The result includes only unique rows from the first query that
do not exist in the second query.
OPerators.pptx Best topics dbms.   Good one
Bitwise Operators
Bitwise operators perform operations at the binary level.
Bitwise operators in DBMS are used to perform
operations at the bit level on integer values. These operators
manipulate individual bits of numbers and are useful in
scenarios like permissions handling, flag operations, and
data compression.
OPerators.pptx Best topics dbms.   Good one
OPerators.pptx Best topics dbms.   Good one
OPerators.pptx Best topics dbms.   Good one
OPerators.pptx Best topics dbms.   Good one
Ad

More Related Content

Similar to OPerators.pptx Best topics dbms. Good one (20)

Sql joins inner join self join outer joins
Sql joins inner join self join outer joinsSql joins inner join self join outer joins
Sql joins inner join self join outer joins
Deepthi Rachumallu
 
Interview Questions.pdf
Interview Questions.pdfInterview Questions.pdf
Interview Questions.pdf
TarunKumar893717
 
DBMS Nested & Sub Queries Set operations
DBMS Nested & Sub Queries Set operationsDBMS Nested & Sub Queries Set operations
DBMS Nested & Sub Queries Set operations
Sreedhar Chowdam
 
MULTIPLE TABLES
MULTIPLE TABLES MULTIPLE TABLES
MULTIPLE TABLES
ASHABOOPATHY
 
1. dml select statement reterive data
1. dml select statement reterive data1. dml select statement reterive data
1. dml select statement reterive data
Amrit Kaur
 
Sql(structured query language)
Sql(structured query language)Sql(structured query language)
Sql(structured query language)
Ishucs
 
Sql Queries
Sql QueriesSql Queries
Sql Queries
webicon
 
set operators.pptx
set operators.pptxset operators.pptx
set operators.pptx
Anusha sivakumar
 
Unions and joins in mysql
Unions and joins in mysqlUnions and joins in mysql
Unions and joins in mysql
baabtra.com - No. 1 supplier of quality freshers
 
sqlyyybdbyehduheufhuehfuheuwehfiewifhewihfiehfiwf
sqlyyybdbyehduheufhuehfuheuwehfiewifhewihfiehfiwfsqlyyybdbyehduheufhuehfuheuwehfiewifhewihfiehfiwf
sqlyyybdbyehduheufhuehfuheuwehfiewifhewihfiehfiwf
kailasmanoj
 
sql joinsubdjbrjdbjrjnfkjcnkrnfknrkfkrfkrfkrk
sql joinsubdjbrjdbjrjnfkjcnkrnfknrkfkrfkrfkrksql joinsubdjbrjdbjrjnfkjcnkrnfknrkfkrfkrfkrk
sql joinsubdjbrjdbjrjnfkjcnkrnfknrkfkrfkrfkrk
kailasmanoj
 
REC-UNIT-2-DATABASEMANAGEMENTSYSTEMS.pptx
REC-UNIT-2-DATABASEMANAGEMENTSYSTEMS.pptxREC-UNIT-2-DATABASEMANAGEMENTSYSTEMS.pptx
REC-UNIT-2-DATABASEMANAGEMENTSYSTEMS.pptx
Uma Kakarlapudi
 
Bootcamp sql fundamentals bootcamp_part1
Bootcamp   sql fundamentals  bootcamp_part1Bootcamp   sql fundamentals  bootcamp_part1
Bootcamp sql fundamentals bootcamp_part1
varunbhatt23
 
Join in SQL - Inner, Self, Outer Join
Join in SQL - Inner, Self, Outer JoinJoin in SQL - Inner, Self, Outer Join
Join in SQL - Inner, Self, Outer Join
Souma Maiti
 
ADV PPT 8 LAB.pptx
ADV PPT 8 LAB.pptxADV PPT 8 LAB.pptx
ADV PPT 8 LAB.pptx
ArjayBalberan1
 
SQL Fundamentals
SQL FundamentalsSQL Fundamentals
SQL Fundamentals
Brian Foote
 
SQL- MOST IMPORTANT CONCEPTS
SQL- MOST IMPORTANT CONCEPTSSQL- MOST IMPORTANT CONCEPTS
SQL- MOST IMPORTANT CONCEPTS
Gagandeep Nanda
 
Using the set operators
Using the set operatorsUsing the set operators
Using the set operators
Syed Zaid Irshad
 
Day-2 SQL Theory_V1.pptx
Day-2 SQL Theory_V1.pptxDay-2 SQL Theory_V1.pptx
Day-2 SQL Theory_V1.pptx
uzmasulthana3
 
SQL Joins and View.pptx
SQL Joins and View.pptxSQL Joins and View.pptx
SQL Joins and View.pptx
pallavipatil634279
 
Sql joins inner join self join outer joins
Sql joins inner join self join outer joinsSql joins inner join self join outer joins
Sql joins inner join self join outer joins
Deepthi Rachumallu
 
DBMS Nested & Sub Queries Set operations
DBMS Nested & Sub Queries Set operationsDBMS Nested & Sub Queries Set operations
DBMS Nested & Sub Queries Set operations
Sreedhar Chowdam
 
1. dml select statement reterive data
1. dml select statement reterive data1. dml select statement reterive data
1. dml select statement reterive data
Amrit Kaur
 
Sql(structured query language)
Sql(structured query language)Sql(structured query language)
Sql(structured query language)
Ishucs
 
Sql Queries
Sql QueriesSql Queries
Sql Queries
webicon
 
sqlyyybdbyehduheufhuehfuheuwehfiewifhewihfiehfiwf
sqlyyybdbyehduheufhuehfuheuwehfiewifhewihfiehfiwfsqlyyybdbyehduheufhuehfuheuwehfiewifhewihfiehfiwf
sqlyyybdbyehduheufhuehfuheuwehfiewifhewihfiehfiwf
kailasmanoj
 
sql joinsubdjbrjdbjrjnfkjcnkrnfknrkfkrfkrfkrk
sql joinsubdjbrjdbjrjnfkjcnkrnfknrkfkrfkrfkrksql joinsubdjbrjdbjrjnfkjcnkrnfknrkfkrfkrfkrk
sql joinsubdjbrjdbjrjnfkjcnkrnfknrkfkrfkrfkrk
kailasmanoj
 
REC-UNIT-2-DATABASEMANAGEMENTSYSTEMS.pptx
REC-UNIT-2-DATABASEMANAGEMENTSYSTEMS.pptxREC-UNIT-2-DATABASEMANAGEMENTSYSTEMS.pptx
REC-UNIT-2-DATABASEMANAGEMENTSYSTEMS.pptx
Uma Kakarlapudi
 
Bootcamp sql fundamentals bootcamp_part1
Bootcamp   sql fundamentals  bootcamp_part1Bootcamp   sql fundamentals  bootcamp_part1
Bootcamp sql fundamentals bootcamp_part1
varunbhatt23
 
Join in SQL - Inner, Self, Outer Join
Join in SQL - Inner, Self, Outer JoinJoin in SQL - Inner, Self, Outer Join
Join in SQL - Inner, Self, Outer Join
Souma Maiti
 
SQL Fundamentals
SQL FundamentalsSQL Fundamentals
SQL Fundamentals
Brian Foote
 
SQL- MOST IMPORTANT CONCEPTS
SQL- MOST IMPORTANT CONCEPTSSQL- MOST IMPORTANT CONCEPTS
SQL- MOST IMPORTANT CONCEPTS
Gagandeep Nanda
 
Day-2 SQL Theory_V1.pptx
Day-2 SQL Theory_V1.pptxDay-2 SQL Theory_V1.pptx
Day-2 SQL Theory_V1.pptx
uzmasulthana3
 

Recently uploaded (20)

LLM finetuning for multiple choice google bert
LLM finetuning for multiple choice google bertLLM finetuning for multiple choice google bert
LLM finetuning for multiple choice google bert
ChadapornK
 
Just-In-Timeasdfffffffghhhhhhhhhhj Systems.ppt
Just-In-Timeasdfffffffghhhhhhhhhhj Systems.pptJust-In-Timeasdfffffffghhhhhhhhhhj Systems.ppt
Just-In-Timeasdfffffffghhhhhhhhhhj Systems.ppt
ssuser5f8f49
 
AI Competitor Analysis: How to Monitor and Outperform Your Competitors
AI Competitor Analysis: How to Monitor and Outperform Your CompetitorsAI Competitor Analysis: How to Monitor and Outperform Your Competitors
AI Competitor Analysis: How to Monitor and Outperform Your Competitors
Contify
 
md-presentHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHation.pptx
md-presentHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHation.pptxmd-presentHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHation.pptx
md-presentHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHation.pptx
fatimalazaar2004
 
Template_A3nnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnn
Template_A3nnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnTemplate_A3nnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnn
Template_A3nnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnn
cegiver630
 
Ch3MCT24.pptx measure of central tendency
Ch3MCT24.pptx measure of central tendencyCh3MCT24.pptx measure of central tendency
Ch3MCT24.pptx measure of central tendency
ayeleasefa2
 
Simple_AI_Explanation_English somplr.pptx
Simple_AI_Explanation_English somplr.pptxSimple_AI_Explanation_English somplr.pptx
Simple_AI_Explanation_English somplr.pptx
ssuser2aa19f
 
183409-christina-rossetti.pdfdsfsdasggsag
183409-christina-rossetti.pdfdsfsdasggsag183409-christina-rossetti.pdfdsfsdasggsag
183409-christina-rossetti.pdfdsfsdasggsag
fardin123rahman07
 
FPET_Implementation_2_MA to 360 Engage Direct.pptx
FPET_Implementation_2_MA to 360 Engage Direct.pptxFPET_Implementation_2_MA to 360 Engage Direct.pptx
FPET_Implementation_2_MA to 360 Engage Direct.pptx
ssuser4ef83d
 
Data Analytics Overview and its applications
Data Analytics Overview and its applicationsData Analytics Overview and its applications
Data Analytics Overview and its applications
JanmejayaMishra7
 
Conic Sectionfaggavahabaayhahahahahs.pptx
Conic Sectionfaggavahabaayhahahahahs.pptxConic Sectionfaggavahabaayhahahahahs.pptx
Conic Sectionfaggavahabaayhahahahahs.pptx
taiwanesechetan
 
Geometry maths presentation for begginers
Geometry maths presentation for begginersGeometry maths presentation for begginers
Geometry maths presentation for begginers
zrjacob283
 
Medical Dataset including visualizations
Medical Dataset including visualizationsMedical Dataset including visualizations
Medical Dataset including visualizations
vishrut8750588758
 
Digilocker under workingProcess Flow.pptx
Digilocker  under workingProcess Flow.pptxDigilocker  under workingProcess Flow.pptx
Digilocker under workingProcess Flow.pptx
satnamsadguru491
 
03 Daniel 2-notes.ppt seminario escatologia
03 Daniel 2-notes.ppt seminario escatologia03 Daniel 2-notes.ppt seminario escatologia
03 Daniel 2-notes.ppt seminario escatologia
Alexander Romero Arosquipa
 
computer organization and assembly language.docx
computer organization and assembly language.docxcomputer organization and assembly language.docx
computer organization and assembly language.docx
alisoftwareengineer1
 
C++_OOPs_DSA1_Presentation_Template.pptx
C++_OOPs_DSA1_Presentation_Template.pptxC++_OOPs_DSA1_Presentation_Template.pptx
C++_OOPs_DSA1_Presentation_Template.pptx
aquibnoor22079
 
Classification_in_Machinee_Learning.pptx
Classification_in_Machinee_Learning.pptxClassification_in_Machinee_Learning.pptx
Classification_in_Machinee_Learning.pptx
wencyjorda88
 
Developing Security Orchestration, Automation, and Response Applications
Developing Security Orchestration, Automation, and Response ApplicationsDeveloping Security Orchestration, Automation, and Response Applications
Developing Security Orchestration, Automation, and Response Applications
VICTOR MAESTRE RAMIREZ
 
Stack_and_Queue_Presentation_Final (1).pptx
Stack_and_Queue_Presentation_Final (1).pptxStack_and_Queue_Presentation_Final (1).pptx
Stack_and_Queue_Presentation_Final (1).pptx
binduraniha86
 
LLM finetuning for multiple choice google bert
LLM finetuning for multiple choice google bertLLM finetuning for multiple choice google bert
LLM finetuning for multiple choice google bert
ChadapornK
 
Just-In-Timeasdfffffffghhhhhhhhhhj Systems.ppt
Just-In-Timeasdfffffffghhhhhhhhhhj Systems.pptJust-In-Timeasdfffffffghhhhhhhhhhj Systems.ppt
Just-In-Timeasdfffffffghhhhhhhhhhj Systems.ppt
ssuser5f8f49
 
AI Competitor Analysis: How to Monitor and Outperform Your Competitors
AI Competitor Analysis: How to Monitor and Outperform Your CompetitorsAI Competitor Analysis: How to Monitor and Outperform Your Competitors
AI Competitor Analysis: How to Monitor and Outperform Your Competitors
Contify
 
md-presentHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHation.pptx
md-presentHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHation.pptxmd-presentHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHation.pptx
md-presentHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHation.pptx
fatimalazaar2004
 
Template_A3nnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnn
Template_A3nnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnTemplate_A3nnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnn
Template_A3nnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnn
cegiver630
 
Ch3MCT24.pptx measure of central tendency
Ch3MCT24.pptx measure of central tendencyCh3MCT24.pptx measure of central tendency
Ch3MCT24.pptx measure of central tendency
ayeleasefa2
 
Simple_AI_Explanation_English somplr.pptx
Simple_AI_Explanation_English somplr.pptxSimple_AI_Explanation_English somplr.pptx
Simple_AI_Explanation_English somplr.pptx
ssuser2aa19f
 
183409-christina-rossetti.pdfdsfsdasggsag
183409-christina-rossetti.pdfdsfsdasggsag183409-christina-rossetti.pdfdsfsdasggsag
183409-christina-rossetti.pdfdsfsdasggsag
fardin123rahman07
 
FPET_Implementation_2_MA to 360 Engage Direct.pptx
FPET_Implementation_2_MA to 360 Engage Direct.pptxFPET_Implementation_2_MA to 360 Engage Direct.pptx
FPET_Implementation_2_MA to 360 Engage Direct.pptx
ssuser4ef83d
 
Data Analytics Overview and its applications
Data Analytics Overview and its applicationsData Analytics Overview and its applications
Data Analytics Overview and its applications
JanmejayaMishra7
 
Conic Sectionfaggavahabaayhahahahahs.pptx
Conic Sectionfaggavahabaayhahahahahs.pptxConic Sectionfaggavahabaayhahahahahs.pptx
Conic Sectionfaggavahabaayhahahahahs.pptx
taiwanesechetan
 
Geometry maths presentation for begginers
Geometry maths presentation for begginersGeometry maths presentation for begginers
Geometry maths presentation for begginers
zrjacob283
 
Medical Dataset including visualizations
Medical Dataset including visualizationsMedical Dataset including visualizations
Medical Dataset including visualizations
vishrut8750588758
 
Digilocker under workingProcess Flow.pptx
Digilocker  under workingProcess Flow.pptxDigilocker  under workingProcess Flow.pptx
Digilocker under workingProcess Flow.pptx
satnamsadguru491
 
computer organization and assembly language.docx
computer organization and assembly language.docxcomputer organization and assembly language.docx
computer organization and assembly language.docx
alisoftwareengineer1
 
C++_OOPs_DSA1_Presentation_Template.pptx
C++_OOPs_DSA1_Presentation_Template.pptxC++_OOPs_DSA1_Presentation_Template.pptx
C++_OOPs_DSA1_Presentation_Template.pptx
aquibnoor22079
 
Classification_in_Machinee_Learning.pptx
Classification_in_Machinee_Learning.pptxClassification_in_Machinee_Learning.pptx
Classification_in_Machinee_Learning.pptx
wencyjorda88
 
Developing Security Orchestration, Automation, and Response Applications
Developing Security Orchestration, Automation, and Response ApplicationsDeveloping Security Orchestration, Automation, and Response Applications
Developing Security Orchestration, Automation, and Response Applications
VICTOR MAESTRE RAMIREZ
 
Stack_and_Queue_Presentation_Final (1).pptx
Stack_and_Queue_Presentation_Final (1).pptxStack_and_Queue_Presentation_Final (1).pptx
Stack_and_Queue_Presentation_Final (1).pptx
binduraniha86
 
Ad

OPerators.pptx Best topics dbms. Good one

  • 3. Operators in Oracle SQL 1. Arithmetic 2. Comparison 3. Logical 4. Bitwise 5. other operations
  • 4. Operator Description Syntax Example Output + Addition SELECT column1 + column2 FROM table; SELECT 10 + 5 FROM dual; 15 - Subtraction SELECT column1 - column2 FROM table; SELECT 10 - 5 FROM dual; 5 * Multiplicati on SELECT column1 * column2 FROM table; SELECT 10 * 5 FROM dual; 50 / Division SELECT column1 / column2 FROM table; SELECT 10 / 5 FROM dual; 2 MOD Modulus (Remainder) SELECT MOD (column1, column2) FROM table; SELECT MOD (10, 3) FROM dual; 1
  • 20. Logical Operators Used to combine multiple conditions.
  • 21. Operator Description Syntax AND Returns TRUE if both conditions are true SELECT * FROM employees WHERE age > 30 AND department = 'HR'; OR Returns TRUE if at least one condition is true SELECT * FROM employees WHERE age > 30 OR department = 'HR'; NOT Negates a condition SELECT * FROM employees WHERE NOT department = 'HR';
  • 23. Concatenation Operator || concatenation operator (||) is used to combine two or more strings into a single string.
  • 25. Set Operators Used to combine the results of multiple SELECT queries.
  • 26. Operator Description Syntax UNION Combines unique records from both queries SELECT column1 FROM table1 UNION SELECT column1 FROM table2; UNION ALL Combines all records (including duplicates) SELECT column1 FROM table1 UNION ALL SELECT column1 FROM table2; INTERSECT Returns common records from both queries SELECT column1 FROM table1 INTERSECT SELECT column1 FROM table2; MINUS Returns records in first query but not in second SELECT column1 FROM table1 MINUS SELECT column1 FROM table2;
  • 29. UNION vs UNION ALL If you want to include duplicate rows, use UNION ALL:
  • 30. The INTERSECT operator in DBMS is used to return the common records (intersection) from two or more SELECT queries. It only includes rows that appear in both result sets.
  • 34.  Both queries must have the same number of columns and data types.  The result includes only unique rows from the first query that do not exist in the second query.
  • 36. Bitwise Operators Bitwise operators perform operations at the binary level.
  • 37. Bitwise operators in DBMS are used to perform operations at the bit level on integer values. These operators manipulate individual bits of numbers and are useful in scenarios like permissions handling, flag operations, and data compression.