DATABASE创建studb数据库?
if exists (select 1 from sysobject where name = 'sp_helpdb') is not null --判断是否存在同名的存储过程,如果有就删除drop procedure sp_helpdb go create procedure sp_helpdb --创建名为sp_helpdb存储过程as create DATABASE studb --在存储过程里创建数据库on primary( --创建主文件 name = studb_mdf, filename = '存储路径\studba_mdf,mdf', size = 3mb, maxsize = 100mb, filegrowth = 1mb)on log( --创建日志文件 name = studb_ldf, filename = '存储路径\studba_ldf,ldf', size = 3mb, maxsize = 200mb, filegrowth = 1mb)go