Wrox Programmer Forums

Need to download code?

View our list of code downloads.

| FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read
BOOK: Professional ASP.NET MVC 2
This is the forum to discuss the Wrox book Professional ASP.NET MVC 2 by Jon Galloway, Scott Hanselman, Phil Haack, Scott Guthrie, Rob Conery; ISBN: Professional ASP.NET MVC 2
Welcome to the p2p.wrox.com Forums.

You are currently viewing the BOOK: Professional ASP.NET MVC 2 section of the Wrox Programmer to Programmer discussions. This is a community of tens of thousands of software programmers and website developers including Wrox book authors and readers. As a guest, you can read any forum posting. By joining today you can post your own programming questions, respond to other developers’ questions, and eliminate the ads that are displayed to guests. Registration is fast, simple and absolutely free .
DRM-free e-books 300x50
 
 
Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old October 9th, 2010, 09:37 PM
Registered User
 
Join Date: Oct 2008
Location: , , .
Posts: 8
Thanks: 0
Thanked 0 Times in 0 Posts
Question Chapter 1 page 14

Hi all,

I have sql server 2005 installed. I am using Visual Studio 2008.
Page 14 goes into creating s sql server express database.

Does anyone know how to connect to sql server 2005.

Last edited by kermit1965; October 9th, 2010 at 09:50 PM..
  #2 (permalink)  
Old October 10th, 2010, 04:10 AM
Authorized User
 
Join Date: Sep 2010
Posts: 13
Thanks: 1
Thanked 1 Time in 1 Post
Default Attaching a database

Quote:
Originally Posted by kermit1965 View Post
Does anyone know how to connect to sql server 2005.
I would still do as taught at page 14. After having created the NerdDinner.mdf file, I will then open SQL management studio, right-click on Databases and select Attach...

From the dialog, I will point to my NerdDinner.mdf file. If you cannot point to the correct location (for some reason, I could point at my computers Documents folder?!), then find the correct path/filename in Explorer and paste the whole path/filename into the dialog. Then it will attach.

I'm not sure if this will cause other problems, but I don't think so :-)
  #3 (permalink)  
Old October 10th, 2010, 12:05 PM
Registered User
 
Join Date: Oct 2008
Location: , , .
Posts: 8
Thanks: 0
Thanked 0 Times in 0 Posts
Default Unable to create database to attach

I just created the database in SQL Server management Studio and connected to it with Server Explorer. It appars that the steps on page 14 are for Sql Express only.

Thanks,

Kermit
  #4 (permalink)  
Old October 11th, 2010, 11:25 AM
Registered User
 
Join Date: Oct 2008
Location: , , .
Posts: 8
Thanks: 0
Thanked 0 Times in 0 Posts
Default Unable to create SQL Express mdf

From Ole F: "I would still do as taught at page 14. After having created the NerdDinner.mdf file, I will then open SQL management studio, right-click on Databases and select Attach..."

The problem is that I cannot create the NerdDinner.mdf file as taught on page 14. On attempting to follow the directions an error message says that I must have SQL Express.


I have an insatnce of Sql Server 2005 developer. I have no instance of Sql Express.


I created the NerdDinner database and the tables and relationships using SQL management studio. I then used VS Server explorer to connect to the data base.

I am having trouble with the publicclassDinnerRepositoryThe example in the book has no using statementsIn one part of the books code:

publicIQueryable<Dinner> FindUpcomingDinners() {
return from dinner in entities.Dinners
where dinner.EventDate > DateTime.Now
orderby dinner.EventDate select dinner;
}

The DateTime object was not recognized until I added "using System;" above the class declaration.

I will probably need to add all appropriate namespaces for the code to work like System.Linq.

In an enterprise application there will be no Sql Express.

Do anyone know how to use Sql Server 2008 for the exercises in the book.

Thanks in advance for any assistance.

-Kermit

Last edited by kermit1965; October 11th, 2010 at 12:12 PM..
  #5 (permalink)  
Old October 11th, 2010, 05:44 PM
Authorized User
 
Join Date: Sep 2010
Posts: 13
Thanks: 1
Thanked 1 Time in 1 Post
Default Download SQL Express for free

My suggestion is that since there are so many errors in the tutorial, I would download a free SQL Express.

A lot of the other errors are corrected in the forum (search for "errata") and there is no need to complicate the tutorial further!

Download the free edition here: http://www.microsoft.com/sqlserver/2...us/try-it.aspx. The third option is the one you want.
  #6 (permalink)  
Old October 11th, 2010, 06:28 PM
Friend of Wrox
Points: 539, Level: 8
Points: 539, Level: 8 Points: 539, Level: 8 Points: 539, Level: 8
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Oct 2010
Location: Seattle
Posts: 106
Thanks: 1
Thanked 17 Times in 17 Posts
Default

I would agree. Trust me, use SQL Express for the moment. You'll need to get other hurdles (and there are many) as you work through Nerd Dinner. Fortunately, most have been addressed in these forums.

I took all the errata I got and used from these forums to reported it to Wrox. Hopefully they will update the official errata.
  #7 (permalink)  
Old October 12th, 2010, 10:10 AM
Registered User
 
Join Date: Oct 2008
Location: , , .
Posts: 8
Thanks: 0
Thanked 0 Times in 0 Posts
Default

I am moving on. Thanks for the input.
 


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Chapter 14 Page 483 tariq BOOK: Beginning ASP.NET 4 : in C# and VB 10 September 14th, 2010 09:35 PM
Chapter 14 Page 548 Try it Out andreas5 BOOK: Beginning ASP.NET 4 : in C# and VB 7 August 22nd, 2010 07:48 AM
Chapter 14:Page 481 try it out lstew452 BOOK: Beginning ASP.NET 3.5 : in C# and VB BOOK ISBN: 978-0-470-18759-3 4 June 20th, 2010 02:35 PM
Chapter 14 page 491 Will BOOK: Beginning ASP.NET 3.5 : in C# and VB BOOK ISBN: 978-0-470-18759-3 4 April 25th, 2009 04:52 AM



All times are GMT -4. The time now is 08:16 PM.


Powered by vBulletin®
Copyright ©2000 - 2019, Jelsoft Enterprises Ltd.
© 2013 John Wiley & Sons, Inc.