SQL VidyaGyan
how to rename database in mssql
How to Rename Database in MsSql
Syntex
sp_renamedb '<Old DatabaseName>','<New DatabaseName>'
Example
sp_renamedb 'Amit','Amit_Kharbanda';
sp_renamedb 'Amit_Kharbanda','Amit' ;
how to check database size in mssql
How to check database size in MsSql
sp_helpdb <databaseName>
sp_helpdb Amit
how to create database in ms sql
How to Create Database in Ms Sql
----------------Create Database-------------
Create database Amiton
(
name = 'Amit_master',
Filename = 'C:\Program Files\Microsoft SQL Server\MSSQL.1\MSSQL\Data\Amit_master.mdf',size = 10mb
)
Log on(
name = 'Amit_log',
Filename = 'C:\Program Files\Microsoft SQL Server\MSSQL.1\MSSQL\Data\Amit_log.ldf',size = 10mb
)
--------------------------OR--------------------------------------------
Create database Amit ;
Subscribe to:
Posts (Atom)