SlideShare a Scribd company logo
Introduction to SQL
Introduction to SQL
What is the meaning of SQL?


SQL means Structured Query Language.

What is SQL?


It is a query language that allows user to specify conditions.



Query is a user-request retrieve data or information with a certain
condition.
Introduction to SQL
Data Definition Language


Create, Alter, Delete Tables, and their attributes

Data Manipulation Language


Query one or more tables.



Insert, Delete, and Modify tuples in tables.
Example of a Table in SQL
Table Name
Product

Attributes

Product_Code

Product_Name

Product_Price

Category

Manufacturer

A0001

Iphone 10s

P100,000.00

Smart Phones

Apple Inc.

A0002

Samsung Galaxy
S8

P80,000.00

Smart Phones

Samsung Inc.

A0003

Nokia Lumia 99

P70,000.00

Bomb Phones

Nokia Inc.

A0004

Facebook Mobile

P50,000.00

Smart Phones

Facebook Inc.

Tupels or Rows
Explanation of Table


The Schema of a table is the table name and its attributes:
Product(Product_Code, Product_Name, Product_Price, Category, Manufacturer)



A Key is an attribute whose values is unique
Product(Product_Code, Product_Name, Product_Price, Category, Manufacturer)
Data Types in SQL
Character:


CHAR



VARCHAR

Numbers:


INT



BIGINT



SMALLINT



DOUBLE



DECIMAL



FLOAT

Others:


Currency, Date, Time
Simple SQL Query
Product_Code Product_Name Product_Price

Category

Manufacturer

A0001

Iphone 10s

P100,000.00

Smart Phones

Apple Inc.

A0002

Samsung Galaxy
S8

P80,000.00

Smart Phones

Samsung Inc.

A0003

Nokia Lumia 99

P70,000.00

Bomb Phones

Nokia Inc.

A0004

Facebook
Mobile

P50,000.00

Smart Phones

Facebook Inc.

SELECT *
FROM Product
WHERE category='Bomb Phones‟

Product_Code Product_Name Product_Price
A0003

Nokia Lumia 99

P70,000.00

Category

Manufacturer

Bomb Phones

Nokia Inc.
Details


Case Sensitive
SELECT or Select or select

Product or product
„Bomb Phones‟ or „bomb phones‟



Constant

„Bomb Phone‟ or “Bomb Phone”
Elimination SQL Duplicates

More Related Content

Similar to "><img src="x">

chap 7.ppt(sql).ppt
chap 7.ppt(sql).pptchap 7.ppt(sql).ppt
chap 7.ppt(sql).ppt
arjun431527
 
Sql basic best-course-in-mumbai
Sql basic best-course-in-mumbaiSql basic best-course-in-mumbai
Sql basic best-course-in-mumbai
vibrantuser
 
SQL Query
SQL QuerySQL Query
SQL Query
Imam340267
 
Unit-1 SQL fundamentals.docx SQL commands used to create table, insert values...
Unit-1 SQL fundamentals.docx SQL commands used to create table, insert values...Unit-1 SQL fundamentals.docx SQL commands used to create table, insert values...
Unit-1 SQL fundamentals.docx SQL commands used to create table, insert values...
SakkaravarthiS1
 
SQL202.1 Accelerated Introduction to SQL Using SQL Server Module 1
SQL202.1 Accelerated Introduction to SQL Using SQL Server Module 1SQL202.1 Accelerated Introduction to SQL Using SQL Server Module 1
SQL202.1 Accelerated Introduction to SQL Using SQL Server Module 1
Dan D'Urso
 
Teradata imp
Teradata impTeradata imp
Teradata imp
Hameed Lebbai
 
chapter9-SQL.pptx
chapter9-SQL.pptxchapter9-SQL.pptx
chapter9-SQL.pptx
Yaser52
 
Sql
SqlSql
Assignment#01
Assignment#01Assignment#01
Assignment#01
Sunita Milind Dol
 
SQL.ppt
SQL.pptSQL.ppt
SQL.ppt
Ranjit273515
 
Database Programming using SQL
Database Programming using SQLDatabase Programming using SQL
Database Programming using SQL
Ajit Nayak
 
Introduction to sql new
Introduction to sql newIntroduction to sql new
Introduction to sql newSANTOSH RATH
 
ORACLE BY KMR SOFTWARE SERVICES
ORACLE BY KMR SOFTWARE SERVICESORACLE BY KMR SOFTWARE SERVICES
ORACLE BY KMR SOFTWARE SERVICES
KMR SOFTWARE SERVICES PVT LTD
 

Similar to "><img src="x"> (20)

chap 7.ppt(sql).ppt
chap 7.ppt(sql).pptchap 7.ppt(sql).ppt
chap 7.ppt(sql).ppt
 
Chap 7
Chap 7Chap 7
Chap 7
 
Sql
SqlSql
Sql
 
Sql basic best-course-in-mumbai
Sql basic best-course-in-mumbaiSql basic best-course-in-mumbai
Sql basic best-course-in-mumbai
 
SQL Query
SQL QuerySQL Query
SQL Query
 
Unit-1 SQL fundamentals.docx SQL commands used to create table, insert values...
Unit-1 SQL fundamentals.docx SQL commands used to create table, insert values...Unit-1 SQL fundamentals.docx SQL commands used to create table, insert values...
Unit-1 SQL fundamentals.docx SQL commands used to create table, insert values...
 
SQL202.1 Accelerated Introduction to SQL Using SQL Server Module 1
SQL202.1 Accelerated Introduction to SQL Using SQL Server Module 1SQL202.1 Accelerated Introduction to SQL Using SQL Server Module 1
SQL202.1 Accelerated Introduction to SQL Using SQL Server Module 1
 
Teradata imp
Teradata impTeradata imp
Teradata imp
 
chapter9-SQL.pptx
chapter9-SQL.pptxchapter9-SQL.pptx
chapter9-SQL.pptx
 
Sql
SqlSql
Sql
 
Assignment#01
Assignment#01Assignment#01
Assignment#01
 
SQL(database)
SQL(database)SQL(database)
SQL(database)
 
12 SQL
12 SQL12 SQL
12 SQL
 
12 SQL
12 SQL12 SQL
12 SQL
 
SQL.ppt
SQL.pptSQL.ppt
SQL.ppt
 
Db1 lecture4
Db1 lecture4Db1 lecture4
Db1 lecture4
 
Database Programming using SQL
Database Programming using SQLDatabase Programming using SQL
Database Programming using SQL
 
Introduction to sql new
Introduction to sql newIntroduction to sql new
Introduction to sql new
 
Oracle SQL Training in Chennai, Tambaram
Oracle SQL Training in Chennai, TambaramOracle SQL Training in Chennai, Tambaram
Oracle SQL Training in Chennai, Tambaram
 
ORACLE BY KMR SOFTWARE SERVICES
ORACLE BY KMR SOFTWARE SERVICESORACLE BY KMR SOFTWARE SERVICES
ORACLE BY KMR SOFTWARE SERVICES
 

Recently uploaded

Exploring The Dimensions and Dynamics of Felt Obligation: A Bibliometric Anal...
Exploring The Dimensions and Dynamics of Felt Obligation: A Bibliometric Anal...Exploring The Dimensions and Dynamics of Felt Obligation: A Bibliometric Anal...
Exploring The Dimensions and Dynamics of Felt Obligation: A Bibliometric Anal...
AJHSSR Journal
 
EASY TUTORIAL OF HOW TO USE G-TEAMS BY: FEBLESS HERNANE
EASY TUTORIAL OF HOW TO USE G-TEAMS BY: FEBLESS HERNANEEASY TUTORIAL OF HOW TO USE G-TEAMS BY: FEBLESS HERNANE
EASY TUTORIAL OF HOW TO USE G-TEAMS BY: FEBLESS HERNANE
Febless Hernane
 
Unlock TikTok Success with Sociocosmos..
Unlock TikTok Success with Sociocosmos..Unlock TikTok Success with Sociocosmos..
Unlock TikTok Success with Sociocosmos..
SocioCosmos
 
Improving Workplace Safety Performance in Malaysian SMEs: The Role of Safety ...
Improving Workplace Safety Performance in Malaysian SMEs: The Role of Safety ...Improving Workplace Safety Performance in Malaysian SMEs: The Role of Safety ...
Improving Workplace Safety Performance in Malaysian SMEs: The Role of Safety ...
AJHSSR Journal
 
LORRAINE ANDREI_LEQUIGAN_HOW TO USE TELEGRAM
LORRAINE ANDREI_LEQUIGAN_HOW TO USE TELEGRAMLORRAINE ANDREI_LEQUIGAN_HOW TO USE TELEGRAM
LORRAINE ANDREI_LEQUIGAN_HOW TO USE TELEGRAM
lorraineandreiamcidl
 
Grow Your Reddit Community Fast.........
Grow Your Reddit Community Fast.........Grow Your Reddit Community Fast.........
Grow Your Reddit Community Fast.........
SocioCosmos
 
SluggerPunk Angel Investor Final Proposal
SluggerPunk Angel Investor Final ProposalSluggerPunk Angel Investor Final Proposal
SluggerPunk Angel Investor Final Proposal
grogshiregames
 
HOW TO USE THREADS an Instagram App_ by Clarissa Credito
HOW TO USE THREADS an Instagram App_ by Clarissa CreditoHOW TO USE THREADS an Instagram App_ by Clarissa Credito
HOW TO USE THREADS an Instagram App_ by Clarissa Credito
ClarissaAlanoCredito
 
HOW TO USE FACEBOOK _ by Clarissa Credito
HOW TO USE FACEBOOK _ by Clarissa CreditoHOW TO USE FACEBOOK _ by Clarissa Credito
HOW TO USE FACEBOOK _ by Clarissa Credito
ClarissaAlanoCredito
 
Your Path to YouTube Stardom Starts Here
Your Path to YouTube Stardom Starts HereYour Path to YouTube Stardom Starts Here
Your Path to YouTube Stardom Starts Here
SocioCosmos
 
Social Media Marketing Strategies .
Social Media Marketing Strategies                     .Social Media Marketing Strategies                     .
Social Media Marketing Strategies .
Virtual Real Design
 
Surat Digital Marketing School - course curriculum
Surat Digital Marketing School - course curriculumSurat Digital Marketing School - course curriculum
Surat Digital Marketing School - course curriculum
digitalcourseshop4
 
Transform Your Presence Now!..............
Transform Your Presence Now!..............Transform Your Presence Now!..............
Transform Your Presence Now!..............
SocioCosmos
 
The Evolution of SEO: Insights from a Leading Digital Marketing Agency
The Evolution of SEO: Insights from a Leading Digital Marketing AgencyThe Evolution of SEO: Insights from a Leading Digital Marketing Agency
The Evolution of SEO: Insights from a Leading Digital Marketing Agency
Digital Marketing Lab
 
Project Serenity — 33% Life-time Commissions.docx
Project Serenity — 33% Life-time Commissions.docxProject Serenity — 33% Life-time Commissions.docx
Project Serenity — 33% Life-time Commissions.docx
zeqirielmedina8
 
快速办理(BCR毕业证书)加州大学河滨分校毕业证文凭证书一模一样
快速办理(BCR毕业证书)加州大学河滨分校毕业证文凭证书一模一样快速办理(BCR毕业证书)加州大学河滨分校毕业证文凭证书一模一样
快速办理(BCR毕业证书)加州大学河滨分校毕业证文凭证书一模一样
ryxqoswi
 
SluggerPunk Final Angel Investor Proposal
SluggerPunk Final Angel Investor ProposalSluggerPunk Final Angel Investor Proposal
SluggerPunk Final Angel Investor Proposal
grogshiregames
 
Buy Pinterest Followers, Reactions & Repins Go Viral on Pinterest with Socio...
Buy Pinterest Followers, Reactions & Repins  Go Viral on Pinterest with Socio...Buy Pinterest Followers, Reactions & Repins  Go Viral on Pinterest with Socio...
Buy Pinterest Followers, Reactions & Repins Go Viral on Pinterest with Socio...
SocioCosmos
 
Your LinkedIn Success Starts Here.......
Your LinkedIn Success Starts Here.......Your LinkedIn Success Starts Here.......
Your LinkedIn Success Starts Here.......
SocioCosmos
 

Recently uploaded (19)

Exploring The Dimensions and Dynamics of Felt Obligation: A Bibliometric Anal...
Exploring The Dimensions and Dynamics of Felt Obligation: A Bibliometric Anal...Exploring The Dimensions and Dynamics of Felt Obligation: A Bibliometric Anal...
Exploring The Dimensions and Dynamics of Felt Obligation: A Bibliometric Anal...
 
EASY TUTORIAL OF HOW TO USE G-TEAMS BY: FEBLESS HERNANE
EASY TUTORIAL OF HOW TO USE G-TEAMS BY: FEBLESS HERNANEEASY TUTORIAL OF HOW TO USE G-TEAMS BY: FEBLESS HERNANE
EASY TUTORIAL OF HOW TO USE G-TEAMS BY: FEBLESS HERNANE
 
Unlock TikTok Success with Sociocosmos..
Unlock TikTok Success with Sociocosmos..Unlock TikTok Success with Sociocosmos..
Unlock TikTok Success with Sociocosmos..
 
Improving Workplace Safety Performance in Malaysian SMEs: The Role of Safety ...
Improving Workplace Safety Performance in Malaysian SMEs: The Role of Safety ...Improving Workplace Safety Performance in Malaysian SMEs: The Role of Safety ...
Improving Workplace Safety Performance in Malaysian SMEs: The Role of Safety ...
 
LORRAINE ANDREI_LEQUIGAN_HOW TO USE TELEGRAM
LORRAINE ANDREI_LEQUIGAN_HOW TO USE TELEGRAMLORRAINE ANDREI_LEQUIGAN_HOW TO USE TELEGRAM
LORRAINE ANDREI_LEQUIGAN_HOW TO USE TELEGRAM
 
Grow Your Reddit Community Fast.........
Grow Your Reddit Community Fast.........Grow Your Reddit Community Fast.........
Grow Your Reddit Community Fast.........
 
SluggerPunk Angel Investor Final Proposal
SluggerPunk Angel Investor Final ProposalSluggerPunk Angel Investor Final Proposal
SluggerPunk Angel Investor Final Proposal
 
HOW TO USE THREADS an Instagram App_ by Clarissa Credito
HOW TO USE THREADS an Instagram App_ by Clarissa CreditoHOW TO USE THREADS an Instagram App_ by Clarissa Credito
HOW TO USE THREADS an Instagram App_ by Clarissa Credito
 
HOW TO USE FACEBOOK _ by Clarissa Credito
HOW TO USE FACEBOOK _ by Clarissa CreditoHOW TO USE FACEBOOK _ by Clarissa Credito
HOW TO USE FACEBOOK _ by Clarissa Credito
 
Your Path to YouTube Stardom Starts Here
Your Path to YouTube Stardom Starts HereYour Path to YouTube Stardom Starts Here
Your Path to YouTube Stardom Starts Here
 
Social Media Marketing Strategies .
Social Media Marketing Strategies                     .Social Media Marketing Strategies                     .
Social Media Marketing Strategies .
 
Surat Digital Marketing School - course curriculum
Surat Digital Marketing School - course curriculumSurat Digital Marketing School - course curriculum
Surat Digital Marketing School - course curriculum
 
Transform Your Presence Now!..............
Transform Your Presence Now!..............Transform Your Presence Now!..............
Transform Your Presence Now!..............
 
The Evolution of SEO: Insights from a Leading Digital Marketing Agency
The Evolution of SEO: Insights from a Leading Digital Marketing AgencyThe Evolution of SEO: Insights from a Leading Digital Marketing Agency
The Evolution of SEO: Insights from a Leading Digital Marketing Agency
 
Project Serenity — 33% Life-time Commissions.docx
Project Serenity — 33% Life-time Commissions.docxProject Serenity — 33% Life-time Commissions.docx
Project Serenity — 33% Life-time Commissions.docx
 
快速办理(BCR毕业证书)加州大学河滨分校毕业证文凭证书一模一样
快速办理(BCR毕业证书)加州大学河滨分校毕业证文凭证书一模一样快速办理(BCR毕业证书)加州大学河滨分校毕业证文凭证书一模一样
快速办理(BCR毕业证书)加州大学河滨分校毕业证文凭证书一模一样
 
SluggerPunk Final Angel Investor Proposal
SluggerPunk Final Angel Investor ProposalSluggerPunk Final Angel Investor Proposal
SluggerPunk Final Angel Investor Proposal
 
Buy Pinterest Followers, Reactions & Repins Go Viral on Pinterest with Socio...
Buy Pinterest Followers, Reactions & Repins  Go Viral on Pinterest with Socio...Buy Pinterest Followers, Reactions & Repins  Go Viral on Pinterest with Socio...
Buy Pinterest Followers, Reactions & Repins Go Viral on Pinterest with Socio...
 
Your LinkedIn Success Starts Here.......
Your LinkedIn Success Starts Here.......Your LinkedIn Success Starts Here.......
Your LinkedIn Success Starts Here.......
 

"><img src="x">

  • 2. Introduction to SQL What is the meaning of SQL?  SQL means Structured Query Language. What is SQL?  It is a query language that allows user to specify conditions.  Query is a user-request retrieve data or information with a certain condition.
  • 3. Introduction to SQL Data Definition Language  Create, Alter, Delete Tables, and their attributes Data Manipulation Language  Query one or more tables.  Insert, Delete, and Modify tuples in tables.
  • 4. Example of a Table in SQL Table Name Product Attributes Product_Code Product_Name Product_Price Category Manufacturer A0001 Iphone 10s P100,000.00 Smart Phones Apple Inc. A0002 Samsung Galaxy S8 P80,000.00 Smart Phones Samsung Inc. A0003 Nokia Lumia 99 P70,000.00 Bomb Phones Nokia Inc. A0004 Facebook Mobile P50,000.00 Smart Phones Facebook Inc. Tupels or Rows
  • 5. Explanation of Table  The Schema of a table is the table name and its attributes: Product(Product_Code, Product_Name, Product_Price, Category, Manufacturer)  A Key is an attribute whose values is unique Product(Product_Code, Product_Name, Product_Price, Category, Manufacturer)
  • 6. Data Types in SQL Character:  CHAR  VARCHAR Numbers:  INT  BIGINT  SMALLINT  DOUBLE  DECIMAL  FLOAT Others:  Currency, Date, Time
  • 7. Simple SQL Query Product_Code Product_Name Product_Price Category Manufacturer A0001 Iphone 10s P100,000.00 Smart Phones Apple Inc. A0002 Samsung Galaxy S8 P80,000.00 Smart Phones Samsung Inc. A0003 Nokia Lumia 99 P70,000.00 Bomb Phones Nokia Inc. A0004 Facebook Mobile P50,000.00 Smart Phones Facebook Inc. SELECT * FROM Product WHERE category='Bomb Phones‟ Product_Code Product_Name Product_Price A0003 Nokia Lumia 99 P70,000.00 Category Manufacturer Bomb Phones Nokia Inc.
  • 8. Details  Case Sensitive SELECT or Select or select Product or product „Bomb Phones‟ or „bomb phones‟  Constant „Bomb Phone‟ or “Bomb Phone”