Last post Mar 23, 2016 07:39 AM by Mikesdotnetting
Mar 23, 2016 05:40 AM|demoninside9|LINK
I have bought some hosting space with sql database. Now I make a sql file by scripting the database from my local machine.
I am doing it like because I don't have access on server's any drive/device otherwise I would have restore it with my
Now I am trying to restore it by querying my scripted file but it shows many error.
The scripted file is as follows
/****** Object: Database [pmscomp] Script Date: 3/23/2016 8:33:42 AM ******/
alter DATABASE [pmscomp]
CONTAINMENT = NONE
( NAME = N'PMS', FILENAME = N'c:\Program Files\Microsoft SQL Server\MSSQL11.SQLEXPRESS\MSSQL\DATA\pmscomp.mdf' , SIZE = 21440KB , MAXSIZE = UNLIMITED, FILEGROWTH = 10%)
( NAME = N'PMS_log', FILENAME = N'c:\Program Files\Microsoft SQL Server\MSSQL11.SQLEXPRESS\MSSQL\DATA\pmscomp_1.ldf' , SIZE = 219264KB , MAXSIZE = UNLIMITED, FILEGROWTH = 10%)
ALTER DATABASE [pmscomp] SET COMPATIBILITY_LEVEL = 90
Do I need to change the path "c:\Program Files\Microsoft SQL Server\MSSQL11.SQLEXPRESS\MSSQL\DATA\pmscomp.mdf" ? but I don't know the exact path.
What to do?
Mar 23, 2016 07:34 AM|JohnsonWelch|LINK
Please have a look on this post: http://blog.sqlauthority.com/2007/02/25/sql-server-restore-database-backup-using-sql-script-t-sql/
Mar 23, 2016 07:39 AM|Mikesdotnetting|LINK
First thing you should do is ask your hosting company for some support - even if it's just to point you to some information that they provide on the way you should do this. The process can differ from one host to another.