Print

Mysql Database

karthikeyan
Written by karthikeyan. Posted in MySQL on 09 November 2009.
Hot 1488 hits 0 favoured

Mysql is a database its is a open source Database software i will give some Basic Syntax in Mysql

Use

Its used to initialized user , Use as keyword

Syntax

USE DatabaseName

Example

MYSQL>USE Name

MYSQL>DATABSE Changed

Create Database

To create a new Database use Following Syntax

Syntax

Create Database  DatabaseName

Example

MYSQL> Create Database Data1

List out Database

Find out what are databases in particular user rights

Syntax

Show Databases

Example

MYSQL>Show Databases

Data1

Describe Database

Its used describe all fields in particular table

Syntax

Describe Tablename

Example

MYSQL>Describe TblValue

ID Int(11)

Name Varchar(50)

Source or .Filename

Execute Sql Script File.

Example

MYSQL>Source.sql  or MYSQL>/.Source.sql

 

To set Privileges

To privileges to control every user rights for read ,write ,modify and delete in data Manipulation languages and Data Definition languages

Syntax

Grant all privileges on *.* to Username

Example

MYSQL> Grant all privileges on Data1 to Name

Set Password

To set password for a particular user

Syntax

Set password for Username=password(‘new password’);

Example

MYSQL>Set password for Name=password(‘ABCD’);

Show Table

To show  all table in particular database use this

Example

MYSQL>Show Tables

Tbl_Mt_Value

Tbl_Mt_Temp


karthikeyan

Author: karthikeyan

16 19871 0
Am software Developer,...
  • No comments found
Powered by CjBlog