SlideShare ist ein Scribd-Unternehmen logo
1 von 2
Downloaden Sie, um offline zu lesen
Using Query in SQL
The following queries are showing the retrieval of data from SQL
table.
--I
Select * from Product order by Product_IDdesc;
--II
select STREET_DTLS,CITY,STATE,POSTCODE from ADDRESS;
--III
select
C.CUST_NAME,C.CUST_EMAIL,C.CUST_PHONE,C.CUST_CONTACT_NAME,C.CUST_CONTA
CT_PHONE,C.CUST_CONTACT_EMAIL,
A.STREET_DTLS,A.CITY,A.STATE from CUSTOMER C,ADDRESS A where
C.ADDRESS_ID=A.ADDRESS_ID ORDER BY C.CUST_NAME DESC;
--IV
SELECT
E.EVENT_ID,C.CUST_NAME,E.LOCATION,E.EVENT_TYPE,E.ATTENDEES,E.EVENT_DAT
E_TIME,E.EVENT_DURATION_EXPTD,E.EVENT_DURATION_ACT FROM EVENT
E,CUSTOMER C WHERE
E.CUST_ID=C.CUST_ID;
--V
SELECT Product_ID,Product_Type,Product_Desc FROM PRODUCT;

Weitere ähnliche Inhalte

Andere mochten auch

Presentación de poleas y mordazas
Presentación de poleas y mordazasPresentación de poleas y mordazas
Presentación de poleas y mordazasVelerisa Industrial
 
Manajemen dss (decision_support_system)_dalam[1]
Manajemen dss (decision_support_system)_dalam[1]Manajemen dss (decision_support_system)_dalam[1]
Manajemen dss (decision_support_system)_dalam[1]milawati30
 
Web Domus Italia - Guida ai servizi
Web Domus Italia - Guida ai servizi Web Domus Italia - Guida ai servizi
Web Domus Italia - Guida ai servizi Web Domus
 
7 tips to improve your relationship
7 tips to improve your relationship7 tips to improve your relationship
7 tips to improve your relationshipSo Cial
 
Relocalisation de l'industrie et mondialisation des données
Relocalisation de l'industrie et mondialisation des donnéesRelocalisation de l'industrie et mondialisation des données
Relocalisation de l'industrie et mondialisation des donnéesAntoine Wintrebert
 
125.careers in zoology
125.careers in zoology125.careers in zoology
125.careers in zoologyentranzz123
 
Fastlane - Automation and Continuous Delivery for iOS Apps
Fastlane - Automation and Continuous Delivery for iOS AppsFastlane - Automation and Continuous Delivery for iOS Apps
Fastlane - Automation and Continuous Delivery for iOS AppsSarath C
 

Andere mochten auch (9)

Presentación de poleas y mordazas
Presentación de poleas y mordazasPresentación de poleas y mordazas
Presentación de poleas y mordazas
 
Manajemen dss (decision_support_system)_dalam[1]
Manajemen dss (decision_support_system)_dalam[1]Manajemen dss (decision_support_system)_dalam[1]
Manajemen dss (decision_support_system)_dalam[1]
 
El patito feo
El  patito feoEl  patito feo
El patito feo
 
Web Domus Italia - Guida ai servizi
Web Domus Italia - Guida ai servizi Web Domus Italia - Guida ai servizi
Web Domus Italia - Guida ai servizi
 
7 tips to improve your relationship
7 tips to improve your relationship7 tips to improve your relationship
7 tips to improve your relationship
 
Relocalisation de l'industrie et mondialisation des données
Relocalisation de l'industrie et mondialisation des donnéesRelocalisation de l'industrie et mondialisation des données
Relocalisation de l'industrie et mondialisation des données
 
125.careers in zoology
125.careers in zoology125.careers in zoology
125.careers in zoology
 
Fastlane - Automation and Continuous Delivery for iOS Apps
Fastlane - Automation and Continuous Delivery for iOS AppsFastlane - Automation and Continuous Delivery for iOS Apps
Fastlane - Automation and Continuous Delivery for iOS Apps
 
Huancarama
HuancaramaHuancarama
Huancarama
 

Kürzlich hochgeladen

Web & Social Media Analytics Previous Year Question Paper.pdf
Web & Social Media Analytics Previous Year Question Paper.pdfWeb & Social Media Analytics Previous Year Question Paper.pdf
Web & Social Media Analytics Previous Year Question Paper.pdfJayanti Pande
 
BAG TECHNIQUE Bag technique-a tool making use of public health bag through wh...
BAG TECHNIQUE Bag technique-a tool making use of public health bag through wh...BAG TECHNIQUE Bag technique-a tool making use of public health bag through wh...
BAG TECHNIQUE Bag technique-a tool making use of public health bag through wh...Sapna Thakur
 
SOCIAL AND HISTORICAL CONTEXT - LFTVD.pptx
SOCIAL AND HISTORICAL CONTEXT - LFTVD.pptxSOCIAL AND HISTORICAL CONTEXT - LFTVD.pptx
SOCIAL AND HISTORICAL CONTEXT - LFTVD.pptxiammrhaywood
 
Class 11th Physics NEET formula sheet pdf
Class 11th Physics NEET formula sheet pdfClass 11th Physics NEET formula sheet pdf
Class 11th Physics NEET formula sheet pdfAyushMahapatra5
 
General AI for Medical Educators April 2024
General AI for Medical Educators April 2024General AI for Medical Educators April 2024
General AI for Medical Educators April 2024Janet Corral
 
Activity 01 - Artificial Culture (1).pdf
Activity 01 - Artificial Culture (1).pdfActivity 01 - Artificial Culture (1).pdf
Activity 01 - Artificial Culture (1).pdfciinovamais
 
Z Score,T Score, Percential Rank and Box Plot Graph
Z Score,T Score, Percential Rank and Box Plot GraphZ Score,T Score, Percential Rank and Box Plot Graph
Z Score,T Score, Percential Rank and Box Plot GraphThiyagu K
 
Beyond the EU: DORA and NIS 2 Directive's Global Impact
Beyond the EU: DORA and NIS 2 Directive's Global ImpactBeyond the EU: DORA and NIS 2 Directive's Global Impact
Beyond the EU: DORA and NIS 2 Directive's Global ImpactPECB
 
social pharmacy d-pharm 1st year by Pragati K. Mahajan
social pharmacy d-pharm 1st year by Pragati K. Mahajansocial pharmacy d-pharm 1st year by Pragati K. Mahajan
social pharmacy d-pharm 1st year by Pragati K. Mahajanpragatimahajan3
 
APM Welcome, APM North West Network Conference, Synergies Across Sectors
APM Welcome, APM North West Network Conference, Synergies Across SectorsAPM Welcome, APM North West Network Conference, Synergies Across Sectors
APM Welcome, APM North West Network Conference, Synergies Across SectorsAssociation for Project Management
 
Ecosystem Interactions Class Discussion Presentation in Blue Green Lined Styl...
Ecosystem Interactions Class Discussion Presentation in Blue Green Lined Styl...Ecosystem Interactions Class Discussion Presentation in Blue Green Lined Styl...
Ecosystem Interactions Class Discussion Presentation in Blue Green Lined Styl...fonyou31
 
1029 - Danh muc Sach Giao Khoa 10 . pdf
1029 -  Danh muc Sach Giao Khoa 10 . pdf1029 -  Danh muc Sach Giao Khoa 10 . pdf
1029 - Danh muc Sach Giao Khoa 10 . pdfQucHHunhnh
 
Software Engineering Methodologies (overview)
Software Engineering Methodologies (overview)Software Engineering Methodologies (overview)
Software Engineering Methodologies (overview)eniolaolutunde
 
A Critique of the Proposed National Education Policy Reform
A Critique of the Proposed National Education Policy ReformA Critique of the Proposed National Education Policy Reform
A Critique of the Proposed National Education Policy ReformChameera Dedduwage
 
microwave assisted reaction. General introduction
microwave assisted reaction. General introductionmicrowave assisted reaction. General introduction
microwave assisted reaction. General introductionMaksud Ahmed
 
Explore beautiful and ugly buildings. Mathematics helps us create beautiful d...
Explore beautiful and ugly buildings. Mathematics helps us create beautiful d...Explore beautiful and ugly buildings. Mathematics helps us create beautiful d...
Explore beautiful and ugly buildings. Mathematics helps us create beautiful d...christianmathematics
 
Introduction to Nonprofit Accounting: The Basics
Introduction to Nonprofit Accounting: The BasicsIntroduction to Nonprofit Accounting: The Basics
Introduction to Nonprofit Accounting: The BasicsTechSoup
 

Kürzlich hochgeladen (20)

Web & Social Media Analytics Previous Year Question Paper.pdf
Web & Social Media Analytics Previous Year Question Paper.pdfWeb & Social Media Analytics Previous Year Question Paper.pdf
Web & Social Media Analytics Previous Year Question Paper.pdf
 
BAG TECHNIQUE Bag technique-a tool making use of public health bag through wh...
BAG TECHNIQUE Bag technique-a tool making use of public health bag through wh...BAG TECHNIQUE Bag technique-a tool making use of public health bag through wh...
BAG TECHNIQUE Bag technique-a tool making use of public health bag through wh...
 
SOCIAL AND HISTORICAL CONTEXT - LFTVD.pptx
SOCIAL AND HISTORICAL CONTEXT - LFTVD.pptxSOCIAL AND HISTORICAL CONTEXT - LFTVD.pptx
SOCIAL AND HISTORICAL CONTEXT - LFTVD.pptx
 
Class 11th Physics NEET formula sheet pdf
Class 11th Physics NEET formula sheet pdfClass 11th Physics NEET formula sheet pdf
Class 11th Physics NEET formula sheet pdf
 
General AI for Medical Educators April 2024
General AI for Medical Educators April 2024General AI for Medical Educators April 2024
General AI for Medical Educators April 2024
 
Activity 01 - Artificial Culture (1).pdf
Activity 01 - Artificial Culture (1).pdfActivity 01 - Artificial Culture (1).pdf
Activity 01 - Artificial Culture (1).pdf
 
Z Score,T Score, Percential Rank and Box Plot Graph
Z Score,T Score, Percential Rank and Box Plot GraphZ Score,T Score, Percential Rank and Box Plot Graph
Z Score,T Score, Percential Rank and Box Plot Graph
 
Beyond the EU: DORA and NIS 2 Directive's Global Impact
Beyond the EU: DORA and NIS 2 Directive's Global ImpactBeyond the EU: DORA and NIS 2 Directive's Global Impact
Beyond the EU: DORA and NIS 2 Directive's Global Impact
 
social pharmacy d-pharm 1st year by Pragati K. Mahajan
social pharmacy d-pharm 1st year by Pragati K. Mahajansocial pharmacy d-pharm 1st year by Pragati K. Mahajan
social pharmacy d-pharm 1st year by Pragati K. Mahajan
 
Mattingly "AI & Prompt Design: The Basics of Prompt Design"
Mattingly "AI & Prompt Design: The Basics of Prompt Design"Mattingly "AI & Prompt Design: The Basics of Prompt Design"
Mattingly "AI & Prompt Design: The Basics of Prompt Design"
 
APM Welcome, APM North West Network Conference, Synergies Across Sectors
APM Welcome, APM North West Network Conference, Synergies Across SectorsAPM Welcome, APM North West Network Conference, Synergies Across Sectors
APM Welcome, APM North West Network Conference, Synergies Across Sectors
 
Advance Mobile Application Development class 07
Advance Mobile Application Development class 07Advance Mobile Application Development class 07
Advance Mobile Application Development class 07
 
Ecosystem Interactions Class Discussion Presentation in Blue Green Lined Styl...
Ecosystem Interactions Class Discussion Presentation in Blue Green Lined Styl...Ecosystem Interactions Class Discussion Presentation in Blue Green Lined Styl...
Ecosystem Interactions Class Discussion Presentation in Blue Green Lined Styl...
 
1029 - Danh muc Sach Giao Khoa 10 . pdf
1029 -  Danh muc Sach Giao Khoa 10 . pdf1029 -  Danh muc Sach Giao Khoa 10 . pdf
1029 - Danh muc Sach Giao Khoa 10 . pdf
 
Software Engineering Methodologies (overview)
Software Engineering Methodologies (overview)Software Engineering Methodologies (overview)
Software Engineering Methodologies (overview)
 
A Critique of the Proposed National Education Policy Reform
A Critique of the Proposed National Education Policy ReformA Critique of the Proposed National Education Policy Reform
A Critique of the Proposed National Education Policy Reform
 
microwave assisted reaction. General introduction
microwave assisted reaction. General introductionmicrowave assisted reaction. General introduction
microwave assisted reaction. General introduction
 
Explore beautiful and ugly buildings. Mathematics helps us create beautiful d...
Explore beautiful and ugly buildings. Mathematics helps us create beautiful d...Explore beautiful and ugly buildings. Mathematics helps us create beautiful d...
Explore beautiful and ugly buildings. Mathematics helps us create beautiful d...
 
Código Creativo y Arte de Software | Unidad 1
Código Creativo y Arte de Software | Unidad 1Código Creativo y Arte de Software | Unidad 1
Código Creativo y Arte de Software | Unidad 1
 
Introduction to Nonprofit Accounting: The Basics
Introduction to Nonprofit Accounting: The BasicsIntroduction to Nonprofit Accounting: The Basics
Introduction to Nonprofit Accounting: The Basics
 

SQL Help

  • 1.
  • 2. Using Query in SQL The following queries are showing the retrieval of data from SQL table. --I Select * from Product order by Product_IDdesc; --II select STREET_DTLS,CITY,STATE,POSTCODE from ADDRESS; --III select C.CUST_NAME,C.CUST_EMAIL,C.CUST_PHONE,C.CUST_CONTACT_NAME,C.CUST_CONTA CT_PHONE,C.CUST_CONTACT_EMAIL, A.STREET_DTLS,A.CITY,A.STATE from CUSTOMER C,ADDRESS A where C.ADDRESS_ID=A.ADDRESS_ID ORDER BY C.CUST_NAME DESC; --IV SELECT E.EVENT_ID,C.CUST_NAME,E.LOCATION,E.EVENT_TYPE,E.ATTENDEES,E.EVENT_DAT E_TIME,E.EVENT_DURATION_EXPTD,E.EVENT_DURATION_ACT FROM EVENT E,CUSTOMER C WHERE E.CUST_ID=C.CUST_ID; --V SELECT Product_ID,Product_Type,Product_Desc FROM PRODUCT;