0% found this document useful (0 votes)
12 views2 pages

Abhisek 2

The document outlines Experiment No. 2, which focuses on studying MySQL and its various data types. It describes how to access the MySQL interface, view databases and tables, and create a new database. The example provided includes commands for logging in and creating a 'Student_admission' database.

Uploaded by

Aman Baghel
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
12 views2 pages

Abhisek 2

The document outlines Experiment No. 2, which focuses on studying MySQL and its various data types. It describes how to access the MySQL interface, view databases and tables, and create a new database. The example provided includes commands for logging in and creating a 'Student_admission' database.

Uploaded by

Aman Baghel
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 2

Enrollment no – 0103IT201011

Experiment No.- 2
Aim: Study MySQL and Various data types used in MySQL. 1. The MySQL interface One
simple (in terms of its appearance and capabilities) way of accessing MySQL is through the
standard interface. To enter the MySQL interface
C:\Users\neeer>mysql -u root -p
Enter password: **********
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 9
Server version: 8.0.28 MySQL Community Server - GPL
Copyright (c) 2000, 2022, Oracle and/or its affiliates.
Oracle is a registered trademark of Oracle Corporation and/or its
affiliates. Other names may be trademarks of their respective
owners.
Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.
mysql>

We can see the databases as:


mysql> show databases;
+--------------------+
| Database |
+--------------------+
| information_schema |
| mysql |
| performance_schema |
| sys |
+--------------------+
4 rows in set (0.20 sec)

We can see tables as:


mysql> show tables;
+-----------------------------+
| Tables_in_student_admission |

Name : Abhishek Prajapati Roll no. 11


Enrollment no – 0103IT201011

+-----------------------------+
| student_data |
+-----------------------------+
1 row in set (0.00 sec)

TO Quit:
mysql> quit;
Bye

2.Basic MySQL administration tools:


Usually only the root user has permission to create new databases and new users for the MySQL
server. The MySQL user is independent of any other username. This means that an individual
may use more than one MySQL username. To enter the MySQL interface as root:
C:\Users\neeer>mysql -u root -p
Enter password: **********

2.1 Create a MySQL database:


It is easy to create a new MySQL table within the MySQL prompt. mysql>
CREATE DATABASE database_name;
mysql> create database Student_admission;
Query OK, 1 row affected (0.17 sec)

Name : Abhishek Prajapati Roll no. 11

You might also like