SlideShare une entreprise Scribd logo
1  sur  11
MySQL Tutorial
Installing MySQL
 Download MySQL 4.0.17 at:
http://www.mysql.com/get/Downloads/MySQL-4.0/mysql-4.0.17-win.zip/from/http://mysql.orst.edu/
 Unzip “mysql-4.0.1-win.zip” and execute “setup.exe”
 Choose a directory, select typical install options.
 Once installation is complete, go to your autoexec.bat file
and put: SET MYSQL_HOME=C:mysql
SET PATH =%MYSQL_HOME%bin;%PATH%
-where “C:mysql” is the location where you installed mysql.
 Once mysql is installed, and your variables are setup,
you need to install the mysql server “service”. To do this type:
C:mysqlbin> mysqld --install //installs the service
C:mysqlbin> NET START MYSQL //start the mysql server
Connecting to the MySQL Server
• SYNTAX: mysql -h host -u user -p
<< EXAMPLE >>
C:mysqlbin> mysql –h localhost –u root –p
NOTE: THE DEFAULT PASSWORD FOR ROOT IS BLANK !!!
Changing “ROOT” password
 GET USER FIRST:
C:mysqlbin> mysql -u root mysql
 CHANGE PASSWORD SYNTAX:
mysql> UPDATE user SET Password=PASSWORD('new_password')
WHERE user='root';
mysql> FLUSH PRIVILEGES;
DON NOT FORGET THE “ ; “ semi-colon
Interfacing with MySQL Server
• The command-line is too cumbersome, we need a GUI!!
• Enter the MySQL Control Center
• Download at:
http://www.mysql.com/get/Downloads/MySQLCC/mysqlcc-
0.9.4-win32.zip/from/http://mysql.orst.edu/
• Unzip mysqlcc-0.9.4-win32.zip and install:
• Open Control Center and Register your MySQL Server
• NAME: Any name you want
• HOST: DNS NAME OR IP-ADDRESS of MySQL SERVER
• USERNAME: Usually root
• PASSWORD: Leave blank, UNLESS you changed it.
Hack the GUI on your own time!
Interfacing with Java: Important Points
• Use ConnectorJ “JDBC Driver”
• Include mysql-connector-java-3.0.10-stable-bin.jar in your
java project
• Import com.mysql.jdbc.Driver;
• Get to know the java.sql.* Package!
Understand “DriverManager” and its relationship with a
“Connection”.
OTHER CLASSES OF USE:
ResultSet - The format Data is retrieved from a Database.
Statement - Used to query a Database for a ResultSet.
CallStatement - Execute a StoredProcedure in the database to
obtain a ResultSet.
Interfacing with Java: Example Code
My sql essentials

Contenu connexe

Tendances

Apache ds building_from_source
Apache ds building_from_sourceApache ds building_from_source
Apache ds building_from_source
mervettt
 
Resources and providers chef conf 2013
Resources and providers chef conf 2013Resources and providers chef conf 2013
Resources and providers chef conf 2013
rosekolodny
 

Tendances (20)

Chef
ChefChef
Chef
 
How to install and configure lamp (linux,apache mysql mariadb,php) with jooml...
How to install and configure lamp (linux,apache mysql mariadb,php) with jooml...How to install and configure lamp (linux,apache mysql mariadb,php) with jooml...
How to install and configure lamp (linux,apache mysql mariadb,php) with jooml...
 
Elastic search
Elastic searchElastic search
Elastic search
 
Links todwnload
Links todwnloadLinks todwnload
Links todwnload
 
Lamp introduction in Fedora
Lamp introduction in FedoraLamp introduction in Fedora
Lamp introduction in Fedora
 
Intalacion de owncloud
Intalacion de owncloudIntalacion de owncloud
Intalacion de owncloud
 
MySql cheat sheet
MySql cheat sheetMySql cheat sheet
MySql cheat sheet
 
Maven: Mule esb plugin
Maven: Mule esb pluginMaven: Mule esb plugin
Maven: Mule esb plugin
 
L5 swagger
L5 swaggerL5 swagger
L5 swagger
 
Apache ds building_from_source
Apache ds building_from_sourceApache ds building_from_source
Apache ds building_from_source
 
Visual Programming Framework for Unity - UniFlow のご紹介
Visual Programming Framework for Unity - UniFlow のご紹介Visual Programming Framework for Unity - UniFlow のご紹介
Visual Programming Framework for Unity - UniFlow のご紹介
 
Elastic Beanstalk 이용한 Django 배포
Elastic Beanstalk 이용한 Django 배포 Elastic Beanstalk 이용한 Django 배포
Elastic Beanstalk 이용한 Django 배포
 
Mysql
Mysql Mysql
Mysql
 
Sql installation
Sql installationSql installation
Sql installation
 
Debian quality assurance systems – What can MariaDB developers learn from them?
Debian quality assurance systems – What can MariaDB developers learn from them?Debian quality assurance systems – What can MariaDB developers learn from them?
Debian quality assurance systems – What can MariaDB developers learn from them?
 
Jones_Lamp_Tutorial
Jones_Lamp_TutorialJones_Lamp_Tutorial
Jones_Lamp_Tutorial
 
Setting up MySQL Replication Cluster in Kubernetes
Setting up MySQL Replication Cluster in KubernetesSetting up MySQL Replication Cluster in Kubernetes
Setting up MySQL Replication Cluster in Kubernetes
 
Resources and providers chef conf 2013
Resources and providers chef conf 2013Resources and providers chef conf 2013
Resources and providers chef conf 2013
 
Bugzilla installation guide
Bugzilla installation guideBugzilla installation guide
Bugzilla installation guide
 
MariaDB in Debian and Ubuntu: The next million users
MariaDB in Debian and Ubuntu: The next million usersMariaDB in Debian and Ubuntu: The next million users
MariaDB in Debian and Ubuntu: The next million users
 

En vedette (8)

Design Document
Design DocumentDesign Document
Design Document
 
Game design for beginners
Game design for beginnersGame design for beginners
Game design for beginners
 
Intro to my sql
Intro to my sqlIntro to my sql
Intro to my sql
 
Unreal gaming design kit basic concepts
Unreal gaming design kit  basic conceptsUnreal gaming design kit  basic concepts
Unreal gaming design kit basic concepts
 
Android development-workshop-v2-1228043706544191-8
Android development-workshop-v2-1228043706544191-8Android development-workshop-v2-1228043706544191-8
Android development-workshop-v2-1228043706544191-8
 
Android Development project
Android Development projectAndroid Development project
Android Development project
 
Extracts from Game Design Document
Extracts from Game Design DocumentExtracts from Game Design Document
Extracts from Game Design Document
 
Study: The Future of VR, AR and Self-Driving Cars
Study: The Future of VR, AR and Self-Driving CarsStudy: The Future of VR, AR and Self-Driving Cars
Study: The Future of VR, AR and Self-Driving Cars
 

Similaire à My sql essentials

R hive tutorial supplement 2 - Installing Hive
R hive tutorial supplement 2 - Installing HiveR hive tutorial supplement 2 - Installing Hive
R hive tutorial supplement 2 - Installing Hive
Aiden Seonghak Hong
 
How to install wordpress on wampserver
How to install wordpress on wampserverHow to install wordpress on wampserver
How to install wordpress on wampserver
shreyakp
 
Bugzilla Installation Process
Bugzilla Installation ProcessBugzilla Installation Process
Bugzilla Installation Process
Vino Harikrishnan
 
Serving Moodle Presentation
Serving Moodle PresentationServing Moodle Presentation
Serving Moodle Presentation
webhostingguy
 

Similaire à My sql essentials (20)

Raj mysql
Raj mysqlRaj mysql
Raj mysql
 
instaling
instalinginstaling
instaling
 
instaling
instalinginstaling
instaling
 
instaling
instalinginstaling
instaling
 
instaling
instalinginstaling
instaling
 
MySQL 8.0.21 - New Features Summary
MySQL 8.0.21 - New Features SummaryMySQL 8.0.21 - New Features Summary
MySQL 8.0.21 - New Features Summary
 
Oracle autovue
Oracle autovueOracle autovue
Oracle autovue
 
Jffnms Manual
Jffnms ManualJffnms Manual
Jffnms Manual
 
Build MySQL virtual enviroment
Build MySQL virtual enviromentBuild MySQL virtual enviroment
Build MySQL virtual enviroment
 
R hive tutorial supplement 2 - Installing Hive
R hive tutorial supplement 2 - Installing HiveR hive tutorial supplement 2 - Installing Hive
R hive tutorial supplement 2 - Installing Hive
 
How to install wordpress on wampserver
How to install wordpress on wampserverHow to install wordpress on wampserver
How to install wordpress on wampserver
 
Mysql ppt
Mysql pptMysql ppt
Mysql ppt
 
PHP environment setup installation
PHP environment setup installation PHP environment setup installation
PHP environment setup installation
 
Bugzilla Installation Process
Bugzilla Installation ProcessBugzilla Installation Process
Bugzilla Installation Process
 
Hdf installing-hdf
Hdf installing-hdfHdf installing-hdf
Hdf installing-hdf
 
Getting started with my sql
Getting started with my sqlGetting started with my sql
Getting started with my sql
 
Set up dev environment
Set up dev environmentSet up dev environment
Set up dev environment
 
Creating a full stack web app with python, npm, webpack and react
Creating a full stack web app with python, npm, webpack and reactCreating a full stack web app with python, npm, webpack and react
Creating a full stack web app with python, npm, webpack and react
 
Serving Moodle Presentation
Serving Moodle PresentationServing Moodle Presentation
Serving Moodle Presentation
 
My sql administration
My sql administrationMy sql administration
My sql administration
 

Dernier

+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
?#DUbAI#??##{{(☎️+971_581248768%)**%*]'#abortion pills for sale in dubai@
 

Dernier (20)

Tech Trends Report 2024 Future Today Institute.pdf
Tech Trends Report 2024 Future Today Institute.pdfTech Trends Report 2024 Future Today Institute.pdf
Tech Trends Report 2024 Future Today Institute.pdf
 
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, AdobeApidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
 
Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...
 
Exploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone ProcessorsExploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone Processors
 
2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...
 
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
 
What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organization
 
AWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of TerraformAWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of Terraform
 
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
 
HTML Injection Attacks: Impact and Mitigation Strategies
HTML Injection Attacks: Impact and Mitigation StrategiesHTML Injection Attacks: Impact and Mitigation Strategies
HTML Injection Attacks: Impact and Mitigation Strategies
 
Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt Robison
 
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
 
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
 
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdfUnderstanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day Presentation
 
Boost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityBoost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivity
 
Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)
 
🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘
 

My sql essentials

  • 2. Installing MySQL  Download MySQL 4.0.17 at: http://www.mysql.com/get/Downloads/MySQL-4.0/mysql-4.0.17-win.zip/from/http://mysql.orst.edu/  Unzip “mysql-4.0.1-win.zip” and execute “setup.exe”  Choose a directory, select typical install options.
  • 3.  Once installation is complete, go to your autoexec.bat file and put: SET MYSQL_HOME=C:mysql SET PATH =%MYSQL_HOME%bin;%PATH% -where “C:mysql” is the location where you installed mysql.  Once mysql is installed, and your variables are setup, you need to install the mysql server “service”. To do this type: C:mysqlbin> mysqld --install //installs the service C:mysqlbin> NET START MYSQL //start the mysql server
  • 4. Connecting to the MySQL Server • SYNTAX: mysql -h host -u user -p << EXAMPLE >> C:mysqlbin> mysql –h localhost –u root –p NOTE: THE DEFAULT PASSWORD FOR ROOT IS BLANK !!!
  • 5. Changing “ROOT” password  GET USER FIRST: C:mysqlbin> mysql -u root mysql  CHANGE PASSWORD SYNTAX: mysql> UPDATE user SET Password=PASSWORD('new_password') WHERE user='root'; mysql> FLUSH PRIVILEGES; DON NOT FORGET THE “ ; “ semi-colon
  • 6. Interfacing with MySQL Server • The command-line is too cumbersome, we need a GUI!! • Enter the MySQL Control Center • Download at: http://www.mysql.com/get/Downloads/MySQLCC/mysqlcc- 0.9.4-win32.zip/from/http://mysql.orst.edu/ • Unzip mysqlcc-0.9.4-win32.zip and install:
  • 7. • Open Control Center and Register your MySQL Server • NAME: Any name you want • HOST: DNS NAME OR IP-ADDRESS of MySQL SERVER • USERNAME: Usually root • PASSWORD: Leave blank, UNLESS you changed it.
  • 8. Hack the GUI on your own time!
  • 9. Interfacing with Java: Important Points • Use ConnectorJ “JDBC Driver” • Include mysql-connector-java-3.0.10-stable-bin.jar in your java project • Import com.mysql.jdbc.Driver; • Get to know the java.sql.* Package! Understand “DriverManager” and its relationship with a “Connection”. OTHER CLASSES OF USE: ResultSet - The format Data is retrieved from a Database. Statement - Used to query a Database for a ResultSet. CallStatement - Execute a StoredProcedure in the database to obtain a ResultSet.
  • 10. Interfacing with Java: Example Code