Mysql添删改查,修改字段属性

1.创建表
	Create table tableName(file type,file type …)
	
2.创建数据库:
	Create database databaseName
3.使用数据库:
	Use databaseName

4.删除表:
	Drop table tableName
	
5.select
	Select * from tableName where file=condiction
	Select * from tableName where file between condiction1 and condiction2
	Select distinct file from tableName where …
	Select count(file/*) from tableName where …
	
6.delete
	Delect from tableName where …
	
7.update 
	Update tableName set file=value where file1=xxx
	
8.insert
	Insert into tableName (files…)values(value…)
	
	
9.数据类型:
	数值型(int,float,double,decimal),string型(char,varchar,blob,text),datatime(date,datetime,timestamp)型
	
10.alter table tableName add/drop/modify/change file type…

 

上一篇:MySql常用内容


下一篇:SQL SERVER动态执行SQL EXEC