<?xml version="1.0" encoding="UTF-8"?><!-- generator="wordpress/2.2.3" -->
<rss version="2.0" 
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	>
<channel>
	<title>Comments on: How to restore (import) a SQL Server database from file</title>
	<link>http://www.csharpuniversity.com/2009/01/16/how-to-restore-import-a-sql-server-database-from-file/</link>
	<description>Quality ASP.NET/C#/SQL Server tutorials, examples, videos and advice</description>
	<pubDate>Sat, 19 May 2012 16:03:12 +0000</pubDate>
	<generator>http://wordpress.org/?v=2.2.3</generator>

	<item>
		<title>By: Denis</title>
		<link>http://www.csharpuniversity.com/2009/01/16/how-to-restore-import-a-sql-server-database-from-file/#comment-280</link>
		<dc:creator>Denis</dc:creator>
		<pubDate>Sat, 08 May 2010 10:16:28 +0000</pubDate>
		<guid>http://www.csharpuniversity.com/2009/01/16/how-to-restore-import-a-sql-server-database-from-file/#comment-280</guid>
		<description>Thanks Ted</description>
		<content:encoded><![CDATA[<p>Thanks Ted</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Neha</title>
		<link>http://www.csharpuniversity.com/2009/01/16/how-to-restore-import-a-sql-server-database-from-file/#comment-248</link>
		<dc:creator>Neha</dc:creator>
		<pubDate>Wed, 13 Jan 2010 07:18:49 +0000</pubDate>
		<guid>http://www.csharpuniversity.com/2009/01/16/how-to-restore-import-a-sql-server-database-from-file/#comment-248</guid>
		<description>Hello,Can u tel me why i am not able to view the other pages,as i navigate to those links...???</description>
		<content:encoded><![CDATA[<p>Hello,Can u tel me why i am not able to view the other pages,as i navigate to those links&#8230;???</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Amish Parekh</title>
		<link>http://www.csharpuniversity.com/2009/01/16/how-to-restore-import-a-sql-server-database-from-file/#comment-157</link>
		<dc:creator>Amish Parekh</dc:creator>
		<pubDate>Sat, 01 Aug 2009 01:25:54 +0000</pubDate>
		<guid>http://www.csharpuniversity.com/2009/01/16/how-to-restore-import-a-sql-server-database-from-file/#comment-157</guid>
		<description>Hello Ted, 

These instructions helped me immensely. I think my issue is now resolved. 

Thank You, 

Amish.</description>
		<content:encoded><![CDATA[<p>Hello Ted, </p>
<p>These instructions helped me immensely. I think my issue is now resolved. </p>
<p>Thank You, </p>
<p>Amish.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: ted</title>
		<link>http://www.csharpuniversity.com/2009/01/16/how-to-restore-import-a-sql-server-database-from-file/#comment-114</link>
		<dc:creator>ted</dc:creator>
		<pubDate>Fri, 22 May 2009 14:25:04 +0000</pubDate>
		<guid>http://www.csharpuniversity.com/2009/01/16/how-to-restore-import-a-sql-server-database-from-file/#comment-114</guid>
		<description>Mad_Dog,
In order to fix this error "5(error not found)" when restoring an SQL Server database, you need to grant Write permission on the target folder to the computer Account or Group that SQL Server is running as.  For you, it looks like the folder you are trying to restore the database to is C:\Program Files\Microsoft SQL Server\MSSQL.1\MSSQL so then try the following steps:

1) Determine what account your SQL Server is running as.  Open Control Panel and go to Services.  Find the service named SQL Server or SQL Server (SQLEXPRESS) and open it up.  Go to the Log On tab and see what account it is using.  For me this is "Sql Server Service".

2) Open Windows Explorer and determine the folder where your database files (*.mdf) are located).  For you the path above is likely where they are.  For others, this location depends on what version of SQL Server you are running so each computer will be different.  For example on my computer the path is C:\Program Files\Microsoft SQL Server\MSSQL10.SQLEXPRESS\MSSQL\DATA

3) Right click on the folder where your database files are and choose Properties.  Go to the Security tab and grant Full Control to the account you found in Step 1 above.</description>
		<content:encoded><![CDATA[<p>Mad_Dog,<br />
In order to fix this error &#8220;5(error not found)&#8221; when restoring an SQL Server database, you need to grant Write permission on the target folder to the computer Account or Group that SQL Server is running as.  For you, it looks like the folder you are trying to restore the database to is C:\Program Files\Microsoft SQL Server\MSSQL.1\MSSQL so then try the following steps:</p>
<p>1) Determine what account your SQL Server is running as.  Open Control Panel and go to Services.  Find the service named SQL Server or SQL Server (SQLEXPRESS) and open it up.  Go to the Log On tab and see what account it is using.  For me this is &#8220;Sql Server Service&#8221;.</p>
<p>2) Open Windows Explorer and determine the folder where your database files (*.mdf) are located).  For you the path above is likely where they are.  For others, this location depends on what version of SQL Server you are running so each computer will be different.  For example on my computer the path is C:\Program Files\Microsoft SQL Server\MSSQL10.SQLEXPRESS\MSSQL\DATA</p>
<p>3) Right click on the folder where your database files are and choose Properties.  Go to the Security tab and grant Full Control to the account you found in Step 1 above.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Mad_Dog</title>
		<link>http://www.csharpuniversity.com/2009/01/16/how-to-restore-import-a-sql-server-database-from-file/#comment-112</link>
		<dc:creator>Mad_Dog</dc:creator>
		<pubDate>Thu, 21 May 2009 16:02:11 +0000</pubDate>
		<guid>http://www.csharpuniversity.com/2009/01/16/how-to-restore-import-a-sql-server-database-from-file/#comment-112</guid>
		<description>I followed the steps above, and I get this error. What happened? Can anyone help me? I`m running Windows Vista Ultimate x86 in Administrator mode, so I have privileges.

===================================

Restore failed for Server 'PRESARIO-PC\SQLEXPRESS'.  (Microsoft.SqlServer.Express.Smo)

------------------------------
Program Location:

   at Microsoft.SqlServer.Management.Smo.Restore.SqlRestore(Server srv)
   at Microsoft.SqlServer.Management.SqlManagerUI.SqlRestoreDatabaseOptions.RunRestore()

===================================

System.Data.SqlClient.SqlError: The operating system returned the error '5(error not found)' while attempting 'RestoreContainer::ValidateTargetForCreation' on 'C:\Program Files\Microsoft SQL Server\MSSQL.1\MSSQL\agenda.mdf'. (Microsoft.SqlServer.Express.Smo)

------------------------------
For help, click: http://go.microsoft.com/fwlink?ProdName=Microsoft+SQL+Server&#38;ProdVer=9.00.3042.00&#38;LinkId=20476

------------------------------
Program Location:

   at Microsoft.SqlServer.Management.Smo.ExecutionManager.ExecuteNonQueryWithMessage(StringCollection queries, ServerMessageEventHandler dbccMessageHandler, Boolean errorsAsMessages)
   at Microsoft.SqlServer.Management.Smo.BackupRestoreBase.ExecuteSql(Server server, StringCollection queries)
   at Microsoft.SqlServer.Management.Smo.Restore.SqlRestore(Server srv)</description>
		<content:encoded><![CDATA[<p>I followed the steps above, and I get this error. What happened? Can anyone help me? I`m running Windows Vista Ultimate x86 in Administrator mode, so I have privileges.</p>
<p>===================================</p>
<p>Restore failed for Server &#8216;PRESARIO-PC\SQLEXPRESS&#8217;.  (Microsoft.SqlServer.Express.Smo)</p>
<p>&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;<br />
Program Location:</p>
<p>   at Microsoft.SqlServer.Management.Smo.Restore.SqlRestore(Server srv)<br />
   at Microsoft.SqlServer.Management.SqlManagerUI.SqlRestoreDatabaseOptions.RunRestore()</p>
<p>===================================</p>
<p>System.Data.SqlClient.SqlError: The operating system returned the error &#8216;5(error not found)&#8217; while attempting &#8216;RestoreContainer::ValidateTargetForCreation&#8217; on &#8216;C:\Program Files\Microsoft SQL Server\MSSQL.1\MSSQL\agenda.mdf&#8217;. (Microsoft.SqlServer.Express.Smo)</p>
<p>&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;<br />
For help, click: <a href="http://go.microsoft.com/fwlink?ProdName=Microsoft+SQL+Server&amp;ProdVer=9.00.3042.00&amp;LinkId=20476" rel="nofollow">http://go.microsoft.com/fwlink?ProdName=Microsoft+SQL+Server&amp;ProdVer=9.00.3042.00&amp;LinkId=20476</a></p>
<p>&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;<br />
Program Location:</p>
<p>   at Microsoft.SqlServer.Management.Smo.ExecutionManager.ExecuteNonQueryWithMessage(StringCollection queries, ServerMessageEventHandler dbccMessageHandler, Boolean errorsAsMessages)<br />
   at Microsoft.SqlServer.Management.Smo.BackupRestoreBase.ExecuteSql(Server server, StringCollection queries)<br />
   at Microsoft.SqlServer.Management.Smo.Restore.SqlRestore(Server srv)</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Sureshkumar</title>
		<link>http://www.csharpuniversity.com/2009/01/16/how-to-restore-import-a-sql-server-database-from-file/#comment-83</link>
		<dc:creator>Sureshkumar</dc:creator>
		<pubDate>Wed, 06 May 2009 08:24:13 +0000</pubDate>
		<guid>http://www.csharpuniversity.com/2009/01/16/how-to-restore-import-a-sql-server-database-from-file/#comment-83</guid>
		<description>Thank's .... restore sql server 2005 
it's working</description>
		<content:encoded><![CDATA[<p>Thank&#8217;s &#8230;. restore sql server 2005<br />
it&#8217;s working</p>
]]></content:encoded>
	</item>
</channel>
</rss>

