SlideShare ist ein Scribd-Unternehmen logo
1 von 29
MYSQL: Introduction
OVERVIEW OF MYSQLwhat is mysql?Where to download mysql?What is database?What is sql?Basic queries in mysql?
MYSQLMysql is the most popular open source database system Mysql is a relational databasemanagement system It is a free SQL server database server licensed with GNU www.gnu.org
STEPS TO DOWNLOAD MYSQL1.goto www.mysql.com2.click on downloads3.choose the host operating system4.download and run mysql5.go back and click on gui tools6.download and run mysql gui tools
DatabaseData: known facts that can be recorded and that have implicit meaningDatabase: collection of related data.It is a logical collection of coherent data with some inherent meaning.DBMS: A computerised record-keeping system.
Goals of a DBMS:To provide an efficient and convenient environment for accessing data in dbIt is a general purpose facility for:Defining dbConstructing dbManipulating db
SQL-structured query languagesql is now the standard language for commercial relational DBMS.It has statements for data definitions, queries and updates.
START MYSQL SERVER:log in as root under linux with the command safe_mysqld &1) without any password:mysql -u <user> -h <host>2)with password:mysql -u <user> -h <host> -p ex: mysql –u root –h localhostdesc: -u option is used to log in as a root and –p option tells mysql to query for the password.
BASIC QUERIES IN MYSQL1.CREATE TABLE    create table table_name(column1 data type(NULL||NOT NULL);desc: creates a table.2.SHOW table    show CREATE TABLE table_name;desc: shows the table in your database.
 3.INSERT insert into table_namevalues[‘value1’,’value2’,……..);desc: inserts new rows of data into the database.4.SELECTselect * from table table_name.desc: returns data from the table.
5.SELECTselect column1,column2,…from table1,table2,….[where conditions][group by column1,column2,..][having conditions][order by column1,column2,…]desc: returns data from one or more database tables.
6.UPDATEupdate table_name set column1=‘value1’,column2=‘values’,…[where conditions]desc: updates existing data in the table.7.DELETEdelete from table_name[where conditions]desc: deletes rows of data from a table.
Mysql classes1.SELECTselect *select col1,col2,…select distinct(column)select count(*)desc: defines columns to display as part of query output.
2.FROMfrom table1,table2,table3,..Desc: defines tables from which to retrieve data.3. GROUP BYgroup by grp_col1,grp_col2,…desc: a form of a sorting.         Used to divide output into logical groups.
4.HAVINGhaving grp_col1=‘value1’AND grp_col2=‘value2’desc: similar to the where clause, used to place conditions on the group clause.5.ORDER BYorder by col1,col2,…desc: used to sort a query’s result.
mysql functions:1.rand()desc: returns random values2.sum()desc: returns the sum of the values.3.now()desc: returns the time and date of the system.4.count()desc: returns the count of the values which satisfy the given condition.
sample code to create a table employee and run  basic queries using mysql on windows operating system: Mysql>create  table employee( Ssn INT NOT NULL, Salary INT, Name VARCHAR(20), Primary key(ssn)); Query ok, 0 rows affected (0.04 sec)
Mysql>insert into employee Values(100,10000,’sneha’,’finance’); Query ok, 1 row affected(0.04 sec) Mysql>insert into employee Values(200,20000,’shalini’,’hr’); Query ok, 1 row affected(0.04 sec)
Mysql>insert into employee Values(300,30000,’john’,’finance’); Query ok, 1 row affected(0.04 sec) Mysql>insert into employee Values(400,40000,’jack’,’hr’); Query ok, 1 row affected(0.04 sec)
Mysql>select * from employee;
Mysql>select department, count(*) as number from employee group by department order by number desc;
Mysql>DESC EMPLOYEE;
Mysql>show create table employee;
Mysql> select name, ssn from employee order by ssn desc limit 2;
Mysql>update employee set salary=9000 where ssn=400;Mysql>select * from employee;
Mysql>delete from employeewhere name=‘jack’;mysql>select * from employee;
Mysql>drop table employee;query ok, 0 rows affected (0.04 sec)Mysql>select * from employee;ERROR 1146 (42S02): Table ‘mysql.employee’ doesn’t existuse quit or exit to come out of mysql.Mysql>quit
Advantages of mysql: 1.Its most reliable. 2.Easy to use. 3.Very fast. 4.Multithreaded multi-user and 5.Robust sql database server.
Visit more self help tutorials Pick a tutorial of your choice and browse through it at your own pace. The tutorials section is free, self-guiding and will not involve any additional support. Visit us at www.dataminingtools.net

Weitere ähnliche Inhalte

Was ist angesagt? (20)

MySql slides (ppt)
MySql slides (ppt)MySql slides (ppt)
MySql slides (ppt)
 
MySQL
MySQLMySQL
MySQL
 
SQL - DML and DDL Commands
SQL - DML and DDL CommandsSQL - DML and DDL Commands
SQL - DML and DDL Commands
 
MySQL Basics
MySQL BasicsMySQL Basics
MySQL Basics
 
Oracle SQL Basics
Oracle SQL BasicsOracle SQL Basics
Oracle SQL Basics
 
Presentation slides of Sequence Query Language (SQL)
Presentation slides of Sequence Query Language (SQL)Presentation slides of Sequence Query Language (SQL)
Presentation slides of Sequence Query Language (SQL)
 
MySQL and its basic commands
MySQL and its basic commandsMySQL and its basic commands
MySQL and its basic commands
 
Get to know PostgreSQL!
Get to know PostgreSQL!Get to know PostgreSQL!
Get to know PostgreSQL!
 
View & index in SQL
View & index in SQLView & index in SQL
View & index in SQL
 
Sql tutorial
Sql tutorialSql tutorial
Sql tutorial
 
Mysql joins
Mysql joinsMysql joins
Mysql joins
 
MySql:Basics
MySql:BasicsMySql:Basics
MySql:Basics
 
Introduction to-sql
Introduction to-sqlIntroduction to-sql
Introduction to-sql
 
Retrieving data using the sql select statement
Retrieving data using the sql select statementRetrieving data using the sql select statement
Retrieving data using the sql select statement
 
MySQL Introduction
MySQL IntroductionMySQL Introduction
MySQL Introduction
 
Oraclesql
OraclesqlOraclesql
Oraclesql
 
Sql server T-sql basics ppt-3
Sql server T-sql basics  ppt-3Sql server T-sql basics  ppt-3
Sql server T-sql basics ppt-3
 
introdution to SQL and SQL functions
introdution to SQL and SQL functionsintrodution to SQL and SQL functions
introdution to SQL and SQL functions
 
Introduction to triggers
Introduction to triggersIntroduction to triggers
Introduction to triggers
 
Database systems introduction
Database systems introductionDatabase systems introduction
Database systems introduction
 

Andere mochten auch

Direct-services portfolio
Direct-services portfolioDirect-services portfolio
Direct-services portfoliovlastakolaja
 
Facebook: An Innovative Influenza Pandemic Early Warning System
Facebook: An Innovative Influenza Pandemic Early Warning SystemFacebook: An Innovative Influenza Pandemic Early Warning System
Facebook: An Innovative Influenza Pandemic Early Warning SystemChen Luo
 
PresentacióN De Quimica
PresentacióN De QuimicaPresentacióN De Quimica
PresentacióN De Quimicaguestf6a53c
 
Facebook: An Innovative Influenza Pandemic Early Warning System
Facebook: An Innovative Influenza Pandemic Early Warning SystemFacebook: An Innovative Influenza Pandemic Early Warning System
Facebook: An Innovative Influenza Pandemic Early Warning SystemChen Luo
 
Presentazione oroblu
Presentazione orobluPresentazione oroblu
Presentazione oroblurobyroby65
 
Pentaho: Reporting Solution Development
Pentaho: Reporting Solution DevelopmentPentaho: Reporting Solution Development
Pentaho: Reporting Solution DevelopmentDataminingTools Inc
 
MS SQL SERVER: Programming sql server data mining
MS SQL SERVER: Programming sql server data miningMS SQL SERVER: Programming sql server data mining
MS SQL SERVER: Programming sql server data miningDataminingTools Inc
 
RapidMiner: Advanced Processes And Operators
RapidMiner:  Advanced Processes And OperatorsRapidMiner:  Advanced Processes And Operators
RapidMiner: Advanced Processes And OperatorsDataminingTools Inc
 

Andere mochten auch (20)

Direct-services portfolio
Direct-services portfolioDirect-services portfolio
Direct-services portfolio
 
Oracle: DML
Oracle: DMLOracle: DML
Oracle: DML
 
SPSS: Data Editor
SPSS: Data EditorSPSS: Data Editor
SPSS: Data Editor
 
Data Applied:Tree Maps
Data Applied:Tree MapsData Applied:Tree Maps
Data Applied:Tree Maps
 
Facebook: An Innovative Influenza Pandemic Early Warning System
Facebook: An Innovative Influenza Pandemic Early Warning SystemFacebook: An Innovative Influenza Pandemic Early Warning System
Facebook: An Innovative Influenza Pandemic Early Warning System
 
PresentacióN De Quimica
PresentacióN De QuimicaPresentacióN De Quimica
PresentacióN De Quimica
 
Introduction to Data-Applied
Introduction to Data-AppliedIntroduction to Data-Applied
Introduction to Data-Applied
 
LISP:Object System Lisp
LISP:Object System LispLISP:Object System Lisp
LISP:Object System Lisp
 
XL-MINER:Partition
XL-MINER:PartitionXL-MINER:Partition
XL-MINER:Partition
 
Matlab Importing Data
Matlab Importing DataMatlab Importing Data
Matlab Importing Data
 
Mphone
MphoneMphone
Mphone
 
Facebook: An Innovative Influenza Pandemic Early Warning System
Facebook: An Innovative Influenza Pandemic Early Warning SystemFacebook: An Innovative Influenza Pandemic Early Warning System
Facebook: An Innovative Influenza Pandemic Early Warning System
 
Data Applied: Association
Data Applied: AssociationData Applied: Association
Data Applied: Association
 
Presentazione oroblu
Presentazione orobluPresentazione oroblu
Presentazione oroblu
 
Control Statements in Matlab
Control Statements in  MatlabControl Statements in  Matlab
Control Statements in Matlab
 
Pentaho: Reporting Solution Development
Pentaho: Reporting Solution DevelopmentPentaho: Reporting Solution Development
Pentaho: Reporting Solution Development
 
MS SQL SERVER: Programming sql server data mining
MS SQL SERVER: Programming sql server data miningMS SQL SERVER: Programming sql server data mining
MS SQL SERVER: Programming sql server data mining
 
RapidMiner: Advanced Processes And Operators
RapidMiner:  Advanced Processes And OperatorsRapidMiner:  Advanced Processes And Operators
RapidMiner: Advanced Processes And Operators
 
MED dra Coding -MSSO
MED dra Coding -MSSOMED dra Coding -MSSO
MED dra Coding -MSSO
 
Clickthrough
ClickthroughClickthrough
Clickthrough
 

Ähnlich wie MySql:Introduction

Introduction databases and MYSQL
Introduction databases and MYSQLIntroduction databases and MYSQL
Introduction databases and MYSQLNaeem Junejo
 
PHP mysql Introduction database
 PHP mysql  Introduction database PHP mysql  Introduction database
PHP mysql Introduction databaseMudasir Syed
 
MySQL Database System Hiep Dinh
MySQL Database System Hiep DinhMySQL Database System Hiep Dinh
MySQL Database System Hiep Dinhwebhostingguy
 
MySQL 8.0 New Features -- September 27th presentation for Open Source Summit
MySQL 8.0 New Features -- September 27th presentation for Open Source SummitMySQL 8.0 New Features -- September 27th presentation for Open Source Summit
MySQL 8.0 New Features -- September 27th presentation for Open Source SummitDave Stokes
 
Linuxfest Northwest 2022 - MySQL 8.0 Nre Features
Linuxfest Northwest 2022 - MySQL 8.0 Nre FeaturesLinuxfest Northwest 2022 - MySQL 8.0 Nre Features
Linuxfest Northwest 2022 - MySQL 8.0 Nre FeaturesDave Stokes
 
Learn PHP Lacture2
Learn PHP Lacture2Learn PHP Lacture2
Learn PHP Lacture2ADARSH BHATT
 
Chapter – 6 SQL Lab Tutorial.pdf
Chapter – 6 SQL Lab Tutorial.pdfChapter – 6 SQL Lab Tutorial.pdf
Chapter – 6 SQL Lab Tutorial.pdfTamiratDejene1
 
mysqlanditsbasiccommands-150226033905-conversion-gate02.pdf
mysqlanditsbasiccommands-150226033905-conversion-gate02.pdfmysqlanditsbasiccommands-150226033905-conversion-gate02.pdf
mysqlanditsbasiccommands-150226033905-conversion-gate02.pdfpradnyamulay
 
Interfacing python to mysql (11363255151).pptx
Interfacing python to mysql (11363255151).pptxInterfacing python to mysql (11363255151).pptx
Interfacing python to mysql (11363255151).pptxcavicav231
 

Ähnlich wie MySql:Introduction (20)

Introduction databases and MYSQL
Introduction databases and MYSQLIntroduction databases and MYSQL
Introduction databases and MYSQL
 
PHP mysql Introduction database
 PHP mysql  Introduction database PHP mysql  Introduction database
PHP mysql Introduction database
 
MySQL Database System Hiep Dinh
MySQL Database System Hiep DinhMySQL Database System Hiep Dinh
MySQL Database System Hiep Dinh
 
mysqlHiep.ppt
mysqlHiep.pptmysqlHiep.ppt
mysqlHiep.ppt
 
My sql1
My sql1My sql1
My sql1
 
MySQL Presentation
MySQL PresentationMySQL Presentation
MySQL Presentation
 
MySQL 8.0 New Features -- September 27th presentation for Open Source Summit
MySQL 8.0 New Features -- September 27th presentation for Open Source SummitMySQL 8.0 New Features -- September 27th presentation for Open Source Summit
MySQL 8.0 New Features -- September 27th presentation for Open Source Summit
 
Linuxfest Northwest 2022 - MySQL 8.0 Nre Features
Linuxfest Northwest 2022 - MySQL 8.0 Nre FeaturesLinuxfest Northwest 2022 - MySQL 8.0 Nre Features
Linuxfest Northwest 2022 - MySQL 8.0 Nre Features
 
Using Mysql.pptx
Using Mysql.pptxUsing Mysql.pptx
Using Mysql.pptx
 
Learn PHP Lacture2
Learn PHP Lacture2Learn PHP Lacture2
Learn PHP Lacture2
 
Chapter – 6 SQL Lab Tutorial.pdf
Chapter – 6 SQL Lab Tutorial.pdfChapter – 6 SQL Lab Tutorial.pdf
Chapter – 6 SQL Lab Tutorial.pdf
 
mysqlanditsbasiccommands-150226033905-conversion-gate02.pdf
mysqlanditsbasiccommands-150226033905-conversion-gate02.pdfmysqlanditsbasiccommands-150226033905-conversion-gate02.pdf
mysqlanditsbasiccommands-150226033905-conversion-gate02.pdf
 
Python database access
Python database accessPython database access
Python database access
 
MySQL with PHP
MySQL with PHPMySQL with PHP
MySQL with PHP
 
Mysql
MysqlMysql
Mysql
 
Mysql python
Mysql pythonMysql python
Mysql python
 
Mysql python
Mysql pythonMysql python
Mysql python
 
Python my SQL - create table
Python my SQL - create tablePython my SQL - create table
Python my SQL - create table
 
Interfacing python to mysql (11363255151).pptx
Interfacing python to mysql (11363255151).pptxInterfacing python to mysql (11363255151).pptx
Interfacing python to mysql (11363255151).pptx
 
Html web sql database
Html web sql databaseHtml web sql database
Html web sql database
 

Mehr von DataminingTools Inc

AI: Introduction to artificial intelligence
AI: Introduction to artificial intelligenceAI: Introduction to artificial intelligence
AI: Introduction to artificial intelligenceDataminingTools Inc
 
Data Mining: Text and web mining
Data Mining: Text and web miningData Mining: Text and web mining
Data Mining: Text and web miningDataminingTools Inc
 
Data Mining: Mining stream time series and sequence data
Data Mining: Mining stream time series and sequence dataData Mining: Mining stream time series and sequence data
Data Mining: Mining stream time series and sequence dataDataminingTools Inc
 
Data Mining: Mining ,associations, and correlations
Data Mining: Mining ,associations, and correlationsData Mining: Mining ,associations, and correlations
Data Mining: Mining ,associations, and correlationsDataminingTools Inc
 
Data Mining: Graph mining and social network analysis
Data Mining: Graph mining and social network analysisData Mining: Graph mining and social network analysis
Data Mining: Graph mining and social network analysisDataminingTools Inc
 
Data warehouse and olap technology
Data warehouse and olap technologyData warehouse and olap technology
Data warehouse and olap technologyDataminingTools Inc
 

Mehr von DataminingTools Inc (20)

Terminology Machine Learning
Terminology Machine LearningTerminology Machine Learning
Terminology Machine Learning
 
Techniques Machine Learning
Techniques Machine LearningTechniques Machine Learning
Techniques Machine Learning
 
Machine learning Introduction
Machine learning IntroductionMachine learning Introduction
Machine learning Introduction
 
Areas of machine leanring
Areas of machine leanringAreas of machine leanring
Areas of machine leanring
 
AI: Planning and AI
AI: Planning and AIAI: Planning and AI
AI: Planning and AI
 
AI: Logic in AI 2
AI: Logic in AI 2AI: Logic in AI 2
AI: Logic in AI 2
 
AI: Logic in AI
AI: Logic in AIAI: Logic in AI
AI: Logic in AI
 
AI: Learning in AI 2
AI: Learning in AI 2AI: Learning in AI 2
AI: Learning in AI 2
 
AI: Learning in AI
AI: Learning in AI AI: Learning in AI
AI: Learning in AI
 
AI: Introduction to artificial intelligence
AI: Introduction to artificial intelligenceAI: Introduction to artificial intelligence
AI: Introduction to artificial intelligence
 
AI: Belief Networks
AI: Belief NetworksAI: Belief Networks
AI: Belief Networks
 
AI: AI & Searching
AI: AI & SearchingAI: AI & Searching
AI: AI & Searching
 
AI: AI & Problem Solving
AI: AI & Problem SolvingAI: AI & Problem Solving
AI: AI & Problem Solving
 
Data Mining: Text and web mining
Data Mining: Text and web miningData Mining: Text and web mining
Data Mining: Text and web mining
 
Data Mining: Outlier analysis
Data Mining: Outlier analysisData Mining: Outlier analysis
Data Mining: Outlier analysis
 
Data Mining: Mining stream time series and sequence data
Data Mining: Mining stream time series and sequence dataData Mining: Mining stream time series and sequence data
Data Mining: Mining stream time series and sequence data
 
Data Mining: Mining ,associations, and correlations
Data Mining: Mining ,associations, and correlationsData Mining: Mining ,associations, and correlations
Data Mining: Mining ,associations, and correlations
 
Data Mining: Graph mining and social network analysis
Data Mining: Graph mining and social network analysisData Mining: Graph mining and social network analysis
Data Mining: Graph mining and social network analysis
 
Data warehouse and olap technology
Data warehouse and olap technologyData warehouse and olap technology
Data warehouse and olap technology
 
Data Mining: Data processing
Data Mining: Data processingData Mining: Data processing
Data Mining: Data processing
 

Kürzlich hochgeladen

How AI, OpenAI, and ChatGPT impact business and software.
How AI, OpenAI, and ChatGPT impact business and software.How AI, OpenAI, and ChatGPT impact business and software.
How AI, OpenAI, and ChatGPT impact business and software.Curtis Poe
 
Decarbonising Buildings: Making a net-zero built environment a reality
Decarbonising Buildings: Making a net-zero built environment a realityDecarbonising Buildings: Making a net-zero built environment a reality
Decarbonising Buildings: Making a net-zero built environment a realityIES VE
 
DevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platformsDevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platformsSergiu Bodiu
 
Sample pptx for embedding into website for demo
Sample pptx for embedding into website for demoSample pptx for embedding into website for demo
Sample pptx for embedding into website for demoHarshalMandlekar2
 
Digital Identity is Under Attack: FIDO Paris Seminar.pptx
Digital Identity is Under Attack: FIDO Paris Seminar.pptxDigital Identity is Under Attack: FIDO Paris Seminar.pptx
Digital Identity is Under Attack: FIDO Paris Seminar.pptxLoriGlavin3
 
The Ultimate Guide to Choosing WordPress Pros and Cons
The Ultimate Guide to Choosing WordPress Pros and ConsThe Ultimate Guide to Choosing WordPress Pros and Cons
The Ultimate Guide to Choosing WordPress Pros and ConsPixlogix Infotech
 
Why device, WIFI, and ISP insights are crucial to supporting remote Microsoft...
Why device, WIFI, and ISP insights are crucial to supporting remote Microsoft...Why device, WIFI, and ISP insights are crucial to supporting remote Microsoft...
Why device, WIFI, and ISP insights are crucial to supporting remote Microsoft...panagenda
 
Assure Ecommerce and Retail Operations Uptime with ThousandEyes
Assure Ecommerce and Retail Operations Uptime with ThousandEyesAssure Ecommerce and Retail Operations Uptime with ThousandEyes
Assure Ecommerce and Retail Operations Uptime with ThousandEyesThousandEyes
 
New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024BookNet Canada
 
Data governance with Unity Catalog Presentation
Data governance with Unity Catalog PresentationData governance with Unity Catalog Presentation
Data governance with Unity Catalog PresentationKnoldus Inc.
 
From Family Reminiscence to Scholarly Archive .
From Family Reminiscence to Scholarly Archive .From Family Reminiscence to Scholarly Archive .
From Family Reminiscence to Scholarly Archive .Alan Dix
 
Unleashing Real-time Insights with ClickHouse_ Navigating the Landscape in 20...
Unleashing Real-time Insights with ClickHouse_ Navigating the Landscape in 20...Unleashing Real-time Insights with ClickHouse_ Navigating the Landscape in 20...
Unleashing Real-time Insights with ClickHouse_ Navigating the Landscape in 20...Alkin Tezuysal
 
Arizona Broadband Policy Past, Present, and Future Presentation 3/25/24
Arizona Broadband Policy Past, Present, and Future Presentation 3/25/24Arizona Broadband Policy Past, Present, and Future Presentation 3/25/24
Arizona Broadband Policy Past, Present, and Future Presentation 3/25/24Mark Goldstein
 
Scale your database traffic with Read & Write split using MySQL Router
Scale your database traffic with Read & Write split using MySQL RouterScale your database traffic with Read & Write split using MySQL Router
Scale your database traffic with Read & Write split using MySQL RouterMydbops
 
Modern Roaming for Notes and Nomad – Cheaper Faster Better Stronger
Modern Roaming for Notes and Nomad – Cheaper Faster Better StrongerModern Roaming for Notes and Nomad – Cheaper Faster Better Stronger
Modern Roaming for Notes and Nomad – Cheaper Faster Better Strongerpanagenda
 
(How to Program) Paul Deitel, Harvey Deitel-Java How to Program, Early Object...
(How to Program) Paul Deitel, Harvey Deitel-Java How to Program, Early Object...(How to Program) Paul Deitel, Harvey Deitel-Java How to Program, Early Object...
(How to Program) Paul Deitel, Harvey Deitel-Java How to Program, Early Object...AliaaTarek5
 
Take control of your SAP testing with UiPath Test Suite
Take control of your SAP testing with UiPath Test SuiteTake control of your SAP testing with UiPath Test Suite
Take control of your SAP testing with UiPath Test SuiteDianaGray10
 
Potential of AI (Generative AI) in Business: Learnings and Insights
Potential of AI (Generative AI) in Business: Learnings and InsightsPotential of AI (Generative AI) in Business: Learnings and Insights
Potential of AI (Generative AI) in Business: Learnings and InsightsRavi Sanghani
 
Generative AI for Technical Writer or Information Developers
Generative AI for Technical Writer or Information DevelopersGenerative AI for Technical Writer or Information Developers
Generative AI for Technical Writer or Information DevelopersRaghuram Pandurangan
 
The Fit for Passkeys for Employee and Consumer Sign-ins: FIDO Paris Seminar.pptx
The Fit for Passkeys for Employee and Consumer Sign-ins: FIDO Paris Seminar.pptxThe Fit for Passkeys for Employee and Consumer Sign-ins: FIDO Paris Seminar.pptx
The Fit for Passkeys for Employee and Consumer Sign-ins: FIDO Paris Seminar.pptxLoriGlavin3
 

Kürzlich hochgeladen (20)

How AI, OpenAI, and ChatGPT impact business and software.
How AI, OpenAI, and ChatGPT impact business and software.How AI, OpenAI, and ChatGPT impact business and software.
How AI, OpenAI, and ChatGPT impact business and software.
 
Decarbonising Buildings: Making a net-zero built environment a reality
Decarbonising Buildings: Making a net-zero built environment a realityDecarbonising Buildings: Making a net-zero built environment a reality
Decarbonising Buildings: Making a net-zero built environment a reality
 
DevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platformsDevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platforms
 
Sample pptx for embedding into website for demo
Sample pptx for embedding into website for demoSample pptx for embedding into website for demo
Sample pptx for embedding into website for demo
 
Digital Identity is Under Attack: FIDO Paris Seminar.pptx
Digital Identity is Under Attack: FIDO Paris Seminar.pptxDigital Identity is Under Attack: FIDO Paris Seminar.pptx
Digital Identity is Under Attack: FIDO Paris Seminar.pptx
 
The Ultimate Guide to Choosing WordPress Pros and Cons
The Ultimate Guide to Choosing WordPress Pros and ConsThe Ultimate Guide to Choosing WordPress Pros and Cons
The Ultimate Guide to Choosing WordPress Pros and Cons
 
Why device, WIFI, and ISP insights are crucial to supporting remote Microsoft...
Why device, WIFI, and ISP insights are crucial to supporting remote Microsoft...Why device, WIFI, and ISP insights are crucial to supporting remote Microsoft...
Why device, WIFI, and ISP insights are crucial to supporting remote Microsoft...
 
Assure Ecommerce and Retail Operations Uptime with ThousandEyes
Assure Ecommerce and Retail Operations Uptime with ThousandEyesAssure Ecommerce and Retail Operations Uptime with ThousandEyes
Assure Ecommerce and Retail Operations Uptime with ThousandEyes
 
New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
 
Data governance with Unity Catalog Presentation
Data governance with Unity Catalog PresentationData governance with Unity Catalog Presentation
Data governance with Unity Catalog Presentation
 
From Family Reminiscence to Scholarly Archive .
From Family Reminiscence to Scholarly Archive .From Family Reminiscence to Scholarly Archive .
From Family Reminiscence to Scholarly Archive .
 
Unleashing Real-time Insights with ClickHouse_ Navigating the Landscape in 20...
Unleashing Real-time Insights with ClickHouse_ Navigating the Landscape in 20...Unleashing Real-time Insights with ClickHouse_ Navigating the Landscape in 20...
Unleashing Real-time Insights with ClickHouse_ Navigating the Landscape in 20...
 
Arizona Broadband Policy Past, Present, and Future Presentation 3/25/24
Arizona Broadband Policy Past, Present, and Future Presentation 3/25/24Arizona Broadband Policy Past, Present, and Future Presentation 3/25/24
Arizona Broadband Policy Past, Present, and Future Presentation 3/25/24
 
Scale your database traffic with Read & Write split using MySQL Router
Scale your database traffic with Read & Write split using MySQL RouterScale your database traffic with Read & Write split using MySQL Router
Scale your database traffic with Read & Write split using MySQL Router
 
Modern Roaming for Notes and Nomad – Cheaper Faster Better Stronger
Modern Roaming for Notes and Nomad – Cheaper Faster Better StrongerModern Roaming for Notes and Nomad – Cheaper Faster Better Stronger
Modern Roaming for Notes and Nomad – Cheaper Faster Better Stronger
 
(How to Program) Paul Deitel, Harvey Deitel-Java How to Program, Early Object...
(How to Program) Paul Deitel, Harvey Deitel-Java How to Program, Early Object...(How to Program) Paul Deitel, Harvey Deitel-Java How to Program, Early Object...
(How to Program) Paul Deitel, Harvey Deitel-Java How to Program, Early Object...
 
Take control of your SAP testing with UiPath Test Suite
Take control of your SAP testing with UiPath Test SuiteTake control of your SAP testing with UiPath Test Suite
Take control of your SAP testing with UiPath Test Suite
 
Potential of AI (Generative AI) in Business: Learnings and Insights
Potential of AI (Generative AI) in Business: Learnings and InsightsPotential of AI (Generative AI) in Business: Learnings and Insights
Potential of AI (Generative AI) in Business: Learnings and Insights
 
Generative AI for Technical Writer or Information Developers
Generative AI for Technical Writer or Information DevelopersGenerative AI for Technical Writer or Information Developers
Generative AI for Technical Writer or Information Developers
 
The Fit for Passkeys for Employee and Consumer Sign-ins: FIDO Paris Seminar.pptx
The Fit for Passkeys for Employee and Consumer Sign-ins: FIDO Paris Seminar.pptxThe Fit for Passkeys for Employee and Consumer Sign-ins: FIDO Paris Seminar.pptx
The Fit for Passkeys for Employee and Consumer Sign-ins: FIDO Paris Seminar.pptx
 

MySql:Introduction

  • 2. OVERVIEW OF MYSQLwhat is mysql?Where to download mysql?What is database?What is sql?Basic queries in mysql?
  • 3. MYSQLMysql is the most popular open source database system Mysql is a relational databasemanagement system It is a free SQL server database server licensed with GNU www.gnu.org
  • 4. STEPS TO DOWNLOAD MYSQL1.goto www.mysql.com2.click on downloads3.choose the host operating system4.download and run mysql5.go back and click on gui tools6.download and run mysql gui tools
  • 5. DatabaseData: known facts that can be recorded and that have implicit meaningDatabase: collection of related data.It is a logical collection of coherent data with some inherent meaning.DBMS: A computerised record-keeping system.
  • 6. Goals of a DBMS:To provide an efficient and convenient environment for accessing data in dbIt is a general purpose facility for:Defining dbConstructing dbManipulating db
  • 7. SQL-structured query languagesql is now the standard language for commercial relational DBMS.It has statements for data definitions, queries and updates.
  • 8. START MYSQL SERVER:log in as root under linux with the command safe_mysqld &1) without any password:mysql -u <user> -h <host>2)with password:mysql -u <user> -h <host> -p ex: mysql –u root –h localhostdesc: -u option is used to log in as a root and –p option tells mysql to query for the password.
  • 9. BASIC QUERIES IN MYSQL1.CREATE TABLE create table table_name(column1 data type(NULL||NOT NULL);desc: creates a table.2.SHOW table show CREATE TABLE table_name;desc: shows the table in your database.
  • 10. 3.INSERT insert into table_namevalues[‘value1’,’value2’,……..);desc: inserts new rows of data into the database.4.SELECTselect * from table table_name.desc: returns data from the table.
  • 11. 5.SELECTselect column1,column2,…from table1,table2,….[where conditions][group by column1,column2,..][having conditions][order by column1,column2,…]desc: returns data from one or more database tables.
  • 12. 6.UPDATEupdate table_name set column1=‘value1’,column2=‘values’,…[where conditions]desc: updates existing data in the table.7.DELETEdelete from table_name[where conditions]desc: deletes rows of data from a table.
  • 13. Mysql classes1.SELECTselect *select col1,col2,…select distinct(column)select count(*)desc: defines columns to display as part of query output.
  • 14. 2.FROMfrom table1,table2,table3,..Desc: defines tables from which to retrieve data.3. GROUP BYgroup by grp_col1,grp_col2,…desc: a form of a sorting. Used to divide output into logical groups.
  • 15. 4.HAVINGhaving grp_col1=‘value1’AND grp_col2=‘value2’desc: similar to the where clause, used to place conditions on the group clause.5.ORDER BYorder by col1,col2,…desc: used to sort a query’s result.
  • 16. mysql functions:1.rand()desc: returns random values2.sum()desc: returns the sum of the values.3.now()desc: returns the time and date of the system.4.count()desc: returns the count of the values which satisfy the given condition.
  • 17. sample code to create a table employee and run basic queries using mysql on windows operating system: Mysql>create table employee( Ssn INT NOT NULL, Salary INT, Name VARCHAR(20), Primary key(ssn)); Query ok, 0 rows affected (0.04 sec)
  • 18. Mysql>insert into employee Values(100,10000,’sneha’,’finance’); Query ok, 1 row affected(0.04 sec) Mysql>insert into employee Values(200,20000,’shalini’,’hr’); Query ok, 1 row affected(0.04 sec)
  • 19. Mysql>insert into employee Values(300,30000,’john’,’finance’); Query ok, 1 row affected(0.04 sec) Mysql>insert into employee Values(400,40000,’jack’,’hr’); Query ok, 1 row affected(0.04 sec)
  • 21. Mysql>select department, count(*) as number from employee group by department order by number desc;
  • 24. Mysql> select name, ssn from employee order by ssn desc limit 2;
  • 25. Mysql>update employee set salary=9000 where ssn=400;Mysql>select * from employee;
  • 26. Mysql>delete from employeewhere name=‘jack’;mysql>select * from employee;
  • 27. Mysql>drop table employee;query ok, 0 rows affected (0.04 sec)Mysql>select * from employee;ERROR 1146 (42S02): Table ‘mysql.employee’ doesn’t existuse quit or exit to come out of mysql.Mysql>quit
  • 28. Advantages of mysql: 1.Its most reliable. 2.Easy to use. 3.Very fast. 4.Multithreaded multi-user and 5.Robust sql database server.
  • 29. Visit more self help tutorials Pick a tutorial of your choice and browse through it at your own pace. The tutorials section is free, self-guiding and will not involve any additional support. Visit us at www.dataminingtools.net