MS SQL入门基础:创建数据库
2007-01-03 09:20:41 来源:WEB开发网create database mydb
on primary
( name = mydb_data1,
filename = 'd:sql datamydb_data1.mdf',
size = 1,
maxsize = unlimited,
filegrowth = 10% ),
filegroup data2
( name = mydb_data2,
filename = 'd:sql datamydb_data2.ndf',
size = 2,
maxsize = 100,
filegrowth = 1 ),
filegroup data3
( name = mydb_data3,
filename = 'd:sql datamydb_data3.ndf',
size = 3,
maxsize = 50,
filegrowth = 500kb )
log on
( name = 'mydb_log1',
filename = 'd:sql datamydb_log1.ldf',
size = 1mb,
maxsize = 25mb,
filegrowth = 10% ),
( name = 'mydb_log2',
filename = 'd:sql datamydb_log2.ldf',
size = 1mb,
maxsize = 10mb,
filegrowth = 10% ),
( name = 'mydb_log3',
filename = 'd:sql datamydb_log3.ldf',
size = 1mb,
maxsize = 5mb,
filegrowth = 512kb )
运行结果如下
-------------------- --------------------
The CREATE DATABASE process is allocating 1.00 MB on disk 'mydb_Data1'.
The CREATE DATABASE process is allocating 2.00 MB on disk 'mydb_Data2'.
The CREATE DATABASE process is allocating 3.00 MB on disk 'mydb_Data3'.
The CREATE DATABASE process is allocating 1.00 MB on disk 'mydb_Log1'.
The CREATE DATABASE process is allocating 1.00 MB on disk 'mydb_Log2'.
The CREATE DATABASE process is allocating 1.00 MB on disk 'mydb_Log3'.
查看全套"MS SQL入门基础教程">>>>>
- ››sql server自动生成批量执行SQL脚本的批处理
- ››sql server 2008亿万数据性能优化
- ››SQL Server 2008清空数据库日志方法
- ››sqlserver安装和简单的使用
- ››SQL Sever 2008 R2 数据库管理
- ››SQL SERVER无法安装成功,sqlstp.log文件提示[未发...
- ››Sql Server中通过父记录查找出所有关联的子记录
- ››SqlServer触发器、存储过程和函数
- ››SQL Server 中的事务(含义,属性,管理)
- ››Sqlite数据库插入和读取图片数据
- ››Sql server 2005拒绝了对对象 'xx表' (数...
- ››Sql server 2005拒绝了对对象 'xx表' (数...
更多精彩
赞助商链接