Learn Python

Learn Data Structure & Algorithm

Learn Numpy

Learn Pandas

Learn Matplotlib

Learn Seaborn

Learn Statistics

Learn Math

Learn MATLAB

Learn Machine learning

Learn Github

Learn OpenCV

Learn Deep Learning

MySQL Introduction

MySQL Setup

MySQL Operators

MySQL Basic Works

MySQL Create Table

MySQL insert and get values

MySQL Condition

MySQL GROUP BY

MySQL Case

MySQL sorting and calculate avg,sum,count

MySQL Update

MySQL Time

MySQL String

MySQL Rollback & Commit

MySQL Join and Concatenate

MySQL Index

MySQL Date

MySQL View

MYSQL With Python

Learn MongoDB

Learn Web scraping

Learn Excel

Learn Power BI

Learn Tableau

Learn Docker

Learn Hadoop

All you need to learn about SQL database

Command to know how many databases are created

Syntax:
show databases;

How to create database?

Syntax:
create database database_name;

Example:
create database Books_store_1;

You have to write the database name in lower case and between multiple words you have to give underscore.

How to use a database?

You can have multiple databases. To use a database among those databases use the code given below

Syntax:
use database_name;

Example:
use Books_store_1;

How to delete a database?

Syntax:
drop databases database_name;

Example:
drop databases Books_store_1;

How to see selected database name?

Suppose you are working on a database for a long time and after sometimes you forget the database name.To get the selected database name use the command given below.

Syntax:
select database();

Example:
select database();

How to see selected database description?

Syntax:
status;

or,

describe database_name;

Example:
describe books_store;

This code will show the database description(name, number of columns, rows, etc) which you have selected for work.

How to see the number of table present in the selected database?

Suppose you select a table for work. Now to know how many tables are present in that database use the given command.

Syntax:
show tables;

Example:
show tables;

CodersAim is created for learning and training a self learner to become a professional from beginner. While using CodersAim, you agree to have read and accepted our terms of use, privacy policy, Contact Us

© Copyright All rights reserved www.CodersAim.com. Developed by CodersAim.