Wrox Programmer Forums
Go Back   Wrox Programmer Forums > .NET > Other .NET > ADO.NET
|
ADO.NET For discussion about ADO.NET.  Topics such as question regarding the System.Data namespace are appropriate.  Questions specific to a particular application should be posted in a forum specific to the application .
Welcome to the p2p.wrox.com Forums.

You are currently viewing the ADO.NET 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 April 4th, 2005, 10:36 PM
Friend of Wrox
 
Join Date: Apr 2004
Posts: 204
Thanks: 0
Thanked 0 Times in 0 Posts
Default Problem with Dataset Update

This project has turned out pretty tricky.

I have a site that loads a dataset from a SQL Server database. The site has several pages, so I persist the dataset using the Session object, e.g.

            Session("ds") = ds.GetXml
            Session("dss") = ds.GetXmlSchema

This works great for maintaining the data and schema between pages, but it doesn't seem to be maintaining the DataViewRowState, because when I call the ds.update method, it generates INSERT instead of Update commands, and I wind up with a table with twice as many records as when I started.

Any ideas? Thanks.

Aaron

 
Old April 29th, 2005, 04:26 AM
Friend of Wrox
 
Join Date: Apr 2005
Posts: 186
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Why can't u put the whole DataSet to the Session?
I think It will solve the issue







Similar Threads
Thread Thread Starter Forum Replies Last Post
update db from dataset nikosnyc VS.NET 2002/2003 1 July 2nd, 2006 06:27 PM
dataset to databse update nashnash ASP.NET 1.0 and 1.1 Professional 1 December 10th, 2004 01:05 PM
How to update the datasource from using dataset syedjavid ADO.NET 3 August 1st, 2004 02:58 PM
Dataset Update with Null Value [V] reyboy ADO.NET 2 June 1st, 2004 12:18 PM





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