 |
BOOK: Beginning ASP.NET 3.5 : in C# and VB BOOK ISBN: 978-0-470-18759-3
 | This is the forum to discuss the Wrox book Beginning ASP.NET 3.5: In C# and VB by Imar Spaanjaars; ISBN: 9780470187593 |
|
Welcome to the p2p.wrox.com Forums.
You are currently viewing the BOOK: Beginning ASP.NET 3.5 : in C# and VB BOOK ISBN: 978-0-470-18759-3 section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
|
|
|
|
|

December 9th, 2010, 07:25 AM
|
|
Authorized User
|
|
Join Date: Dec 2010
Posts: 38
Thanks: 8
Thanked 0 Times in 0 Posts
|
|
Database cannot be opened
Hi,
I'm trying to continue the book but on another PC. I try to access the PlanetWrox database and I get the following error.
http://i156.photobucket.com/albums/t13/GRiT_02/DB.jpg
Thanks
|
|

December 9th, 2010, 07:30 AM
|
 |
Wrox Author
|
|
Join Date: Jun 2003
Posts: 17,089
Thanks: 80
Thanked 1,576 Times in 1,552 Posts
|
|
Hi there,
Sounds like you have SQL Server 2008 R2 on the source machine, but the earlier SQL Server 2008 on the target machine. Databases are not backwards compatible from R2 to the initial version (although they are forwards compatible from 2008 to 2008 R2).
Hope this helps,
Imar
|
|

December 9th, 2010, 09:08 AM
|
 |
Wrox Author
|
|
Join Date: Jun 2003
Posts: 17,089
Thanks: 80
Thanked 1,576 Times in 1,552 Posts
|
|
That's weird. The book was written against Visual Studio 2008 and uses SQL Server Express 2005, so you should definitely be able to open it with 2008 or 2008 R2.
How exactly are you trying to open the database? Do you have multiple instances of SQL Server installed? Is J:\ a network share and if so have you tried doing this from a local disk?
Imar
|
|

December 9th, 2010, 09:15 AM
|
 |
Wrox Author
|
|
Join Date: Jun 2003
Posts: 17,089
Thanks: 80
Thanked 1,576 Times in 1,552 Posts
|
|
Just found this:
http://social.msdn.microsoft.com/For...5-c2182b709e18
Looks like you can't use SQL 2008 databases with VS 2008, so you either need to upgrade to VS 2010, or downgrade to (or install side by side) a copy of SQL Server Express 2005.
Cheers,
Imar
|
|

December 9th, 2010, 09:24 AM
|
|
Authorized User
|
|
Join Date: Dec 2010
Posts: 38
Thanks: 8
Thanked 0 Times in 0 Posts
|
|
Thanks for the response.
Strange thing is, it works on my home PC which also has sql 2008 and VWD 2008 installed.
I'll try sql server 2005 and see if it works.
Thanks
|
|

December 9th, 2010, 09:32 AM
|
 |
Wrox Author
|
|
Join Date: Jun 2003
Posts: 17,089
Thanks: 80
Thanked 1,576 Times in 1,552 Posts
|
|
I looked into this a bit more and it seems that it does work, provided you have Service Pack 1 for Visual Studio 2008 installed. I just added the PlanetWrox.mdf file (from Beginning ASP.NET 3.5 which means it's a SQL Server 2005 file) to the App_Data folder of a new web site, told Visual Studio to use my Sql2008Express instance (using Tools | Options | Database Tools | Data Connections | Instance Name) and then it worked fine when I double-clicked the MDF file in App_Data.
What about the other questions I asked?
Imar
|
|
The Following User Says Thank You to Imar For This Useful Post:
|
|
|

December 9th, 2010, 10:05 AM
|
|
Authorized User
|
|
Join Date: Dec 2010
Posts: 38
Thanks: 8
Thanked 0 Times in 0 Posts
|
|
Quote:
Originally Posted by Imar
How exactly are you trying to open the database? Do you have multiple instances of SQL Server installed? Is J:\ a network share and if so have you tried doing this from a local disk?
Imar
|
I've tried to open the database in SSMS for 2008 r2 and that fails too.
J:\ is a usb pen flash drive that I'm using to transfer the whole application from my home PC to my work PC. I've used both this and a local drive and neither works.
I had both sql server 2008 and 2008 r2 but have now uninstalled sql 2008
Quote:
|
I looked into this a bit more and it seems that it does work, provided you have Service Pack 1 for Visual Studio 2008 installed. I just added the PlanetWrox.mdf file (from Beginning ASP.NET 3.5 which means it's a SQL Server 2005 file) to the App_Data folder of a new web site, told Visual Studio to use my Sql2008Express instance (using Tools | Options | Database Tools | Data Connections | Instance Name) and then it worked fine when I double-clicked the MDF file in App_Data.
|
I'm only using VWD 2008 express and dont have those options.
|
|

December 9th, 2010, 10:17 AM
|
 |
Wrox Author
|
|
Join Date: Jun 2003
Posts: 17,089
Thanks: 80
Thanked 1,576 Times in 1,552 Posts
|
|
Quote:
|
I'm only using VWD 2008 express and dont have those options.
|
It's there on my copy of VWD 2008 Express. Are you sure you installed SP1 and enabled "Show all settings" in the Options dialog?
Once you see that dialog, make sure that the instance name matches the one of your Express instance, whatever that name may be.
Imar
|
|
The Following User Says Thank You to Imar For This Useful Post:
|
|
|

December 9th, 2010, 11:31 AM
|
|
Authorized User
|
|
Join Date: Dec 2010
Posts: 38
Thanks: 8
Thanked 0 Times in 0 Posts
|
|
Still not working. The instance is set to SQLEXPRESS but it still doesnt work.
I'm going to give up on it and simply create the PlanetWrox database on my works PC.
Thanks for your help
Last edited by GeeTee991100; December 9th, 2010 at 11:36 AM..
|
|
 |