–1 use master backup database logTest to disk=’D:\\Program Files\\Microsoft SQL Server\\MSSQL10.MSSQLSERVER\\MSSQL\\Backup\\logTest.bak’ with format –2 use logTest create table table_1(Id int, test varchar(max)) insert table_1(Id,test) values (1,’333
修改数据库字符集:
代码如下:
ALTER DATABASE db_name DEFAULT CHARACTER SET character_name [COLLATE …];
把表默认的字符集和所有字符列(CHAR,VARCHAR,TEXT)改为新的字符集:
代码如下:
ALTER TABLE tbl_name CONVERT TO CHARACTER SET character_name [COLLATE …]
如:ALTER TABLE logtest CONVERT TO