Answered by:
some code error in the excersise book of sql server2008

Question
-
hello,
I am trying to learn sql server2008 from the book mike hotek mstc exam 70-432 wat the book tells me first download adventureworks*.msi file ,but I found from internet that this file is replaced with adventureworks2008_SR4 so I downloaded this file and installed it.after the book tells me start new query and enter the following code and execute
EXEC
sp_configure ' filestream_acces_level' 2
;
GO
RECONFIGURE
GO
RESTORE
DATABASE AdventureWorks FROM DISK='C:\Program Files\Microsoft SQL Server\100\Tools\Samples\AdventureWorks2008.bak' WITH RECOVERY
;
GO
RESTORE
DATABASE AdventureWorksDW FROM DISK='C:\Program Files\Microsoft SQL Server\100\Tools\Samples\AdventureWorksDW2008.bak' WITH RECOVERY
;
Go
so I did it and he gives this error code
Msg 102, Level 15, State 1, Line 1
Incorrect syntax near '2'.
Msg 3201, Level 16, State 2, Line 1
Cannot open backup device 'C:\Program Files\Microsoft SQL Server\100\Tools\Samples\AdventureWorks2008.bak'. Operating system error 2(The system cannot find the file specified.).
Msg 3013, Level 16, State 1, Line 1
RESTORE DATABASE is terminating abnormally.
Msg 3201, Level 16, State 2, Line 1
Cannot open backup device 'C:\Program Files\Microsoft SQL Server\100\Tools\Samples\AdventureWorksDW2008.bak'. Operating system error 2(The system cannot find the file specified.).
Msg 3013, Level 16, State 1, Line 1
RESTORE DATABASE is terminating abnormally. I don't know wat to do and i don't understand nothing I konnow something is wrong. i am just start to learn SQL server2008 .can somebody give me advise wat to do.
thanks
johan
h.davidWednesday, July 27, 2011 11:13 AM
Answers
-
Errata is on
http://oreilly.com/catalog/errata.csp?isbn=9780735626058
Cheers
Craig
www.mspress.com.au
Craig Roberts Woodslane- Marked as answer by Rubel Khan Friday, November 25, 2011 5:46 AM
Thursday, July 28, 2011 12:08 AM -
Have a read of the following thread as it explains what to do about this error http://social.msdn.microsoft.com/Forums/en-US/sqlserversamples/thread/c97c32ee-3e4c-4bd4-9720-9a7589acea15/
Jeff Wharton
MSysDev (C.Sturt), MDbDsgnMgt (C.Sturt), MCT, MCPD, MCITP, MCDBA
Blog: Mr. Wharty's Ramblings
MC ID: Microsoft Transcript
Please mark answered if I've answered your question and vote for it as helpful to help other user's find a solution quicker- Proposed as answer by Alberto PoblacionMVP Friday, July 29, 2011 9:01 AM
- Marked as answer by Rubel Khan Friday, November 25, 2011 5:46 AM
Wednesday, July 27, 2011 11:57 AM
All replies
-
Have a read of the following thread as it explains what to do about this error http://social.msdn.microsoft.com/Forums/en-US/sqlserversamples/thread/c97c32ee-3e4c-4bd4-9720-9a7589acea15/
Jeff Wharton
MSysDev (C.Sturt), MDbDsgnMgt (C.Sturt), MCT, MCPD, MCITP, MCDBA
Blog: Mr. Wharty's Ramblings
MC ID: Microsoft Transcript
Please mark answered if I've answered your question and vote for it as helpful to help other user's find a solution quicker- Proposed as answer by Alberto PoblacionMVP Friday, July 29, 2011 9:01 AM
- Marked as answer by Rubel Khan Friday, November 25, 2011 5:46 AM
Wednesday, July 27, 2011 11:57 AM -
Errata is on
http://oreilly.com/catalog/errata.csp?isbn=9780735626058
Cheers
Craig
www.mspress.com.au
Craig Roberts Woodslane- Marked as answer by Rubel Khan Friday, November 25, 2011 5:46 AM
Thursday, July 28, 2011 12:08 AM