Wrox Programmer Forums
|
BOOK: Beginning ASP.NET 1.1
This is the forum to discuss the Wrox book Beginning ASP.NET 1.1 with Visual C#.NET 2003 by Chris Ullman, John Kauffman, Chris Hart, Dave Sussman, Daniel Maharry; ISBN: 9780764557088
Welcome to the p2p.wrox.com Forums.

You are currently viewing the BOOK: Beginning ASP.NET 1.1 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
 
Old June 17th, 2005, 08:39 AM
Registered User
 
Join Date: Jun 2005
Posts: 9
Thanks: 0
Thanked 0 Times in 0 Posts
Default Chapter 9 - Try It Out on Page 306

I'm having some trouble getting this example to work. The only edit I've made to the code is to change the connectionString to that appropriate for a database running on my local machine, the rest of the example having been downloaded directly from the sample online code. The error I'm getting is that the call to

Code:
dataAdapter.Update(data, "Employees")
, which appears on Line 92 in the original sample code, produces the error

Code:
System.Data.OleDb.OleDbException: Operation must use an updateable query.
The query in question, I take it, is the

Code:
SELECT EmployeeID, FirstName, LastName FROM Employees;
one used to instantiate the dataAdapter?

I've checked this query physically within Northwind.mdb, and it produces an editable result using Access's own query tool. I've tried removing all relationships with other tables in Northwind to see if that fixed the problem, but had no luck with that.

Do any of you have any ideas on what's producing the error?

Thanks, Rach.
 
Old June 18th, 2005, 04:59 AM
Registered User
 
Join Date: Jun 2005
Posts: 9
Thanks: 0
Thanked 0 Times in 0 Posts
Default

I've been having a further look at this problem, and it seems to be an issue that's specific to Visual Studio and/or IIS. The code runs fine on Web Matrix's own web server.
 
Old June 18th, 2005, 05:59 AM
Imar's Avatar
Wrox Author
 
Join Date: Jun 2003
Posts: 17,089
Thanks: 80
Thanked 1,576 Times in 1,552 Posts
Default

This sounds like a permissions issue to me.

Apparently, the Web Matrix web server runs under a different user account than IIS.

Check out this FAQ to find out how to fix this:

http://imar.spaanjaars.com/QuickDocId.aspx?QUICKDOC=263

HtH,

Imar
---------------------------------------
Imar Spaanjaars
Everyone is unique, except for me.
 
Old June 18th, 2005, 06:25 AM
Registered User
 
Join Date: Jun 2005
Posts: 9
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Thank you, Imar; that's exactly what the problem was. I really appreciate you taking the time to help.

Rach. :)
 
Old June 18th, 2005, 11:40 AM
Imar's Avatar
Wrox Author
 
Join Date: Jun 2003
Posts: 17,089
Thanks: 80
Thanked 1,576 Times in 1,552 Posts
Default

You're welcome. Glad it's working.

Imar
---------------------------------------
Imar Spaanjaars
Everyone is unique, except for me.





Similar Threads
Thread Thread Starter Forum Replies Last Post
Chapter 3, Page 110 ntonline1 BOOK: Beginning PHP5, Apache, and MySQL Web Development ISBN: 978-0-7645-7966-0 1 March 2nd, 2011 10:06 AM
Chapter 7 - page 212 asplundo BOOK: Beginning ASP.NET 2.0 BOOK VB ISBN: 978-0-7645-8850-1; C# ISBN: 978-0-470-04258-8 3 February 2nd, 2008 06:56 AM
chapter 3.0 try it out page 74 rat BOOK: Beginning ASP.NET 2.0 BOOK VB ISBN: 978-0-7645-8850-1; C# ISBN: 978-0-470-04258-8 5 August 3rd, 2006 01:51 PM
exam 70-306(Dev & Impl Wind App with VB.Net subhanak General .NET 0 May 25th, 2006 11:41 AM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.