SlideShare ist ein Scribd-Unternehmen logo
1 von 14
CIT 407
T-SQL Queries Design and Tuning
What is a database
• an organized collection of structured data
• stored electronically in a computer system
• controlled by a database management system (DBMS)
• data, the DBMS and applications are referred as a
database system
• data is typically modeled in rows and columns
• in a series of tables to make processing and data
querying efficient
• data can then be easily accessed, managed, modified,
updated, controlled, and organized
• Relational databases use structured query language
(SQL) for writing and querying data.
• SQL is a programming language used by nearly
all relational databases to query, manipulate, and define
data, and to provide access control.
• SQL was first developed at IBM in the 1970s which led to
implementation of the SQL ANSI standard
• SQL has spurred many extensions from companies such
as IBM, Oracle, Microsoft, MySQL
There are many different types of databases
• Relational databases
• Object-oriented databases
• Distributed databases
• Data warehouses
• NoSQL databases
• Graph databases
• OLTP databases
• Open source databases
• Cloud databases
• Multimodel database
• Document/JSON database
• Self-driving databases
Relational databases
• Items in a relational database are organized as a
set of tables with columns and rows
• Relational database technology provides the
most efficient and flexible way to access
structured information
What is data modelling
• is the process of creating a data model for the data to be stored
in a database
• Conceptual representation of Data objects, the associations
between different data objects and the rules
• Data modeling helps in the visual representation of data and
enforces business rules, regulatory compliances, and
government policies on the data
• Data Models ensure consistency in naming conventions, default
values, semantics, security while ensuring quality of the data
The two types of Data Models techniques are
1. Entity Relationship (E-R) Model
2. UML (Unified Modelling Language)
There are three types of data models:
1. Conceptual
2. Logical
3. Physical
The main aim of this model is to establish the entities, their
attributes, and their relationships.
In this data modeling level, there is hardly any detail
available of the actual database structure.
Conceptual Model
The 3 basic tenants of Data Model are
Entity: A real-world thing
Attribute: Characteristics or properties of an entity
Relationship: Dependency or association between two
entities
Conceptual Model
For example:
• customer and product are two entities
• customer number and name are attributes of the
customer entity
• product name and price are attributes of product entity
• sale is the relationship between the customer and
product
customer name
customer number
product name
product price
sale
Entity relationship diagram
Customer buys
product from
website
product
A sale is recorded
Item is shipped to customer
Inventory gets replenished
Item is purchased
from suppliers

Weitere ähnliche Inhalte

Was ist angesagt?

Mergenthaler mis405 1301 a-01 ph 1 ip
Mergenthaler mis405 1301 a-01 ph 1 ipMergenthaler mis405 1301 a-01 ph 1 ip
Mergenthaler mis405 1301 a-01 ph 1 ipSabrina Mergenthaler
 
Introduction to Database
Introduction to DatabaseIntroduction to Database
Introduction to DatabaseFARHAN615
 
Type of Database Management System
Type of Database Management SystemType of Database Management System
Type of Database Management SystemParam Radadiya
 
Artifacts, Data Dictionary, Data Modeling, Data Wrangling
Artifacts, Data Dictionary, Data Modeling, Data WranglingArtifacts, Data Dictionary, Data Modeling, Data Wrangling
Artifacts, Data Dictionary, Data Modeling, Data WranglingFaisal Akbar
 
Database management system
Database management systemDatabase management system
Database management systemrishi ram khanal
 
Application of Unified Modelling Language
Application of Unified Modelling LanguageApplication of Unified Modelling Language
Application of Unified Modelling LanguageRasan Samarasinghe
 
data and information
data and informationdata and information
data and informationuzmajamal
 
International Journal of Database Management Systems (IJDBMS)
International Journal of Database Management Systems (IJDBMS)International Journal of Database Management Systems (IJDBMS)
International Journal of Database Management Systems (IJDBMS)MiajackB
 
Database Management Systems 1
Database Management Systems 1Database Management Systems 1
Database Management Systems 1Nickkisha Farrell
 
RDBMS Arch & Models
RDBMS Arch & ModelsRDBMS Arch & Models
RDBMS Arch & ModelsSarmad Ali
 
International Journal of Database Management Systems (IJDBMS)
International Journal of Database Management Systems (IJDBMS)International Journal of Database Management Systems (IJDBMS)
International Journal of Database Management Systems (IJDBMS)ijfcst journal
 
International Journal of Database Management Systems (IJDBMS)
International Journal of Database Management Systems (IJDBMS)International Journal of Database Management Systems (IJDBMS)
International Journal of Database Management Systems (IJDBMS)ijfcst journal
 
International Journal of Database Management Systems (IJDBMS)
International Journal of Database Management Systems (IJDBMS)International Journal of Database Management Systems (IJDBMS)
International Journal of Database Management Systems (IJDBMS)ijfcst journal
 
International Journal of Database Management Systems (IJDMS)
International Journal of Database Management Systems (IJDMS)International Journal of Database Management Systems (IJDMS)
International Journal of Database Management Systems (IJDMS)ijdms
 

Was ist angesagt? (20)

Mergenthaler mis405 1301 a-01 ph 1 ip
Mergenthaler mis405 1301 a-01 ph 1 ipMergenthaler mis405 1301 a-01 ph 1 ip
Mergenthaler mis405 1301 a-01 ph 1 ip
 
Database and types of databases
Database and types of databasesDatabase and types of databases
Database and types of databases
 
Introduction to Database
Introduction to DatabaseIntroduction to Database
Introduction to Database
 
Type of Database Management System
Type of Database Management SystemType of Database Management System
Type of Database Management System
 
Artifacts, Data Dictionary, Data Modeling, Data Wrangling
Artifacts, Data Dictionary, Data Modeling, Data WranglingArtifacts, Data Dictionary, Data Modeling, Data Wrangling
Artifacts, Data Dictionary, Data Modeling, Data Wrangling
 
Database management system
Database management systemDatabase management system
Database management system
 
Data Modeling
Data ModelingData Modeling
Data Modeling
 
Application of Unified Modelling Language
Application of Unified Modelling LanguageApplication of Unified Modelling Language
Application of Unified Modelling Language
 
data and information
data and informationdata and information
data and information
 
DSA
DSADSA
DSA
 
Data model
Data modelData model
Data model
 
Databases and types of databases
Databases and types of databasesDatabases and types of databases
Databases and types of databases
 
International Journal of Database Management Systems (IJDBMS)
International Journal of Database Management Systems (IJDBMS)International Journal of Database Management Systems (IJDBMS)
International Journal of Database Management Systems (IJDBMS)
 
Database Management Systems 1
Database Management Systems 1Database Management Systems 1
Database Management Systems 1
 
RDBMS Arch & Models
RDBMS Arch & ModelsRDBMS Arch & Models
RDBMS Arch & Models
 
Database and types of database
Database and types of databaseDatabase and types of database
Database and types of database
 
International Journal of Database Management Systems (IJDBMS)
International Journal of Database Management Systems (IJDBMS)International Journal of Database Management Systems (IJDBMS)
International Journal of Database Management Systems (IJDBMS)
 
International Journal of Database Management Systems (IJDBMS)
International Journal of Database Management Systems (IJDBMS)International Journal of Database Management Systems (IJDBMS)
International Journal of Database Management Systems (IJDBMS)
 
International Journal of Database Management Systems (IJDBMS)
International Journal of Database Management Systems (IJDBMS)International Journal of Database Management Systems (IJDBMS)
International Journal of Database Management Systems (IJDBMS)
 
International Journal of Database Management Systems (IJDMS)
International Journal of Database Management Systems (IJDMS)International Journal of Database Management Systems (IJDMS)
International Journal of Database Management Systems (IJDMS)
 

Ähnlich wie T-SQL

Ähnlich wie T-SQL (20)

(Dbms) class 1 & 2 (Presentation)
(Dbms) class 1 & 2 (Presentation)(Dbms) class 1 & 2 (Presentation)
(Dbms) class 1 & 2 (Presentation)
 
Utsav Mahendra : Introduction to Database and managemnet
Utsav Mahendra : Introduction to Database and managemnetUtsav Mahendra : Introduction to Database and managemnet
Utsav Mahendra : Introduction to Database and managemnet
 
Dbms
DbmsDbms
Dbms
 
dbms Unit 1.pdf arey bhai teri maa chodunga
dbms Unit 1.pdf arey bhai teri maa chodungadbms Unit 1.pdf arey bhai teri maa chodunga
dbms Unit 1.pdf arey bhai teri maa chodunga
 
lecture5 (1) (2).pptx
lecture5 (1) (2).pptxlecture5 (1) (2).pptx
lecture5 (1) (2).pptx
 
Dbms
DbmsDbms
Dbms
 
Dbms unit 1
Dbms unit 1Dbms unit 1
Dbms unit 1
 
DBMS data modeling.pptx
DBMS data modeling.pptxDBMS data modeling.pptx
DBMS data modeling.pptx
 
01-Database Administration and Management.pdf
01-Database Administration and Management.pdf01-Database Administration and Management.pdf
01-Database Administration and Management.pdf
 
Digital data
Digital dataDigital data
Digital data
 
Digital Types
Digital TypesDigital Types
Digital Types
 
Data modelling it's process and examples
Data modelling it's process and examplesData modelling it's process and examples
Data modelling it's process and examples
 
Sql server ___________session_1-intro
Sql server  ___________session_1-introSql server  ___________session_1-intro
Sql server ___________session_1-intro
 
Data Modeling Training.pptx
Data Modeling Training.pptxData Modeling Training.pptx
Data Modeling Training.pptx
 
DatabaseManagementSystem.pptx
DatabaseManagementSystem.pptxDatabaseManagementSystem.pptx
DatabaseManagementSystem.pptx
 
Access
AccessAccess
Access
 
Unit1 DBMS Introduction
Unit1 DBMS IntroductionUnit1 DBMS Introduction
Unit1 DBMS Introduction
 
BAB 7 Pangkalan data new
BAB 7   Pangkalan data newBAB 7   Pangkalan data new
BAB 7 Pangkalan data new
 
RowanDay4.pptx
RowanDay4.pptxRowanDay4.pptx
RowanDay4.pptx
 
DBMS
DBMS DBMS
DBMS
 

Kürzlich hochgeladen

#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024BookNet Canada
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationMichael W. Hawkins
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerThousandEyes
 
Swan(sea) Song – personal research during my six years at Swansea ... and bey...
Swan(sea) Song – personal research during my six years at Swansea ... and bey...Swan(sea) Song – personal research during my six years at Swansea ... and bey...
Swan(sea) Song – personal research during my six years at Swansea ... and bey...Alan Dix
 
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking MenDelhi Call girls
 
CNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of ServiceCNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of Servicegiselly40
 
🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘RTylerCroy
 
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfThe Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfEnterprise Knowledge
 
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountBreaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountPuma Security, LLC
 
Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)Allon Mureinik
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsEnterprise Knowledge
 
My Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationMy Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationRidwan Fadjar
 
Unblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesUnblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesSinan KOZAK
 
Understanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitectureUnderstanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitecturePixlogix Infotech
 
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...Neo4j
 
Enhancing Worker Digital Experience: A Hands-on Workshop for Partners
Enhancing Worker Digital Experience: A Hands-on Workshop for PartnersEnhancing Worker Digital Experience: A Hands-on Workshop for Partners
Enhancing Worker Digital Experience: A Hands-on Workshop for PartnersThousandEyes
 
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhi
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | DelhiFULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhi
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhisoniya singh
 
Histor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slideHistor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slidevu2urc
 
How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonetsnaman860154
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024Rafal Los
 

Kürzlich hochgeladen (20)

#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day Presentation
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
Swan(sea) Song – personal research during my six years at Swansea ... and bey...
Swan(sea) Song – personal research during my six years at Swansea ... and bey...Swan(sea) Song – personal research during my six years at Swansea ... and bey...
Swan(sea) Song – personal research during my six years at Swansea ... and bey...
 
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men
 
CNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of ServiceCNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of Service
 
🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘
 
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfThe Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
 
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountBreaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path Mount
 
Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI Solutions
 
My Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationMy Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 Presentation
 
Unblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesUnblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen Frames
 
Understanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitectureUnderstanding the Laravel MVC Architecture
Understanding the Laravel MVC Architecture
 
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
 
Enhancing Worker Digital Experience: A Hands-on Workshop for Partners
Enhancing Worker Digital Experience: A Hands-on Workshop for PartnersEnhancing Worker Digital Experience: A Hands-on Workshop for Partners
Enhancing Worker Digital Experience: A Hands-on Workshop for Partners
 
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhi
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | DelhiFULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhi
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhi
 
Histor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slideHistor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slide
 
How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonets
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024
 

T-SQL

  • 1. CIT 407 T-SQL Queries Design and Tuning
  • 2. What is a database
  • 3. • an organized collection of structured data • stored electronically in a computer system • controlled by a database management system (DBMS) • data, the DBMS and applications are referred as a database system • data is typically modeled in rows and columns • in a series of tables to make processing and data querying efficient • data can then be easily accessed, managed, modified, updated, controlled, and organized
  • 4. • Relational databases use structured query language (SQL) for writing and querying data. • SQL is a programming language used by nearly all relational databases to query, manipulate, and define data, and to provide access control. • SQL was first developed at IBM in the 1970s which led to implementation of the SQL ANSI standard • SQL has spurred many extensions from companies such as IBM, Oracle, Microsoft, MySQL
  • 5. There are many different types of databases • Relational databases • Object-oriented databases • Distributed databases • Data warehouses • NoSQL databases • Graph databases • OLTP databases • Open source databases • Cloud databases • Multimodel database • Document/JSON database • Self-driving databases
  • 6. Relational databases • Items in a relational database are organized as a set of tables with columns and rows • Relational database technology provides the most efficient and flexible way to access structured information
  • 7. What is data modelling • is the process of creating a data model for the data to be stored in a database • Conceptual representation of Data objects, the associations between different data objects and the rules • Data modeling helps in the visual representation of data and enforces business rules, regulatory compliances, and government policies on the data • Data Models ensure consistency in naming conventions, default values, semantics, security while ensuring quality of the data
  • 8. The two types of Data Models techniques are 1. Entity Relationship (E-R) Model 2. UML (Unified Modelling Language)
  • 9. There are three types of data models: 1. Conceptual 2. Logical 3. Physical
  • 10. The main aim of this model is to establish the entities, their attributes, and their relationships. In this data modeling level, there is hardly any detail available of the actual database structure. Conceptual Model
  • 11. The 3 basic tenants of Data Model are Entity: A real-world thing Attribute: Characteristics or properties of an entity Relationship: Dependency or association between two entities Conceptual Model
  • 12. For example: • customer and product are two entities • customer number and name are attributes of the customer entity • product name and price are attributes of product entity • sale is the relationship between the customer and product
  • 13. customer name customer number product name product price sale Entity relationship diagram
  • 14. Customer buys product from website product A sale is recorded Item is shipped to customer Inventory gets replenished Item is purchased from suppliers