473,396 Members | 1,982 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

Dataset being overwritten by multiple users?

I've got an aspnet page (vb) that runs a stored procedure, pipes it in
a dataset, and binds to a gridview. The parameters for the stored
procedure are some URL variables. My problem is when multiple ( 2 or
more) people click on this link at the exact same time, the dataset
seems to be getting overwritten. If person A clicks on their link,
and person B clicks on theirs at the same time, person A is getting
Person B's data, and vice versa. I'm almost positive this has
something to do with multiple accessing the dataset at the same time.
Is this the case? What's the workaround? TIA
Mar 12 '08 #1
3 1252
Chris wrote:
Makes sense now. Good ol' hindsight. So what other options do I have
if I want to put this query in a dataset, but retain the information
in the dataset after postbacks?
You can save data in the Session state (but I have a nagging suspicion that
a dataset is not serializable, so you'd have to figure out a way to get the
data into something that is, like an ArrayList).

Andrew
Mar 12 '08 #2
"Andrew Morton" <ak*@in-press.co.uk.invalidwrote in message
news:eU**************@TK2MSFTNGP06.phx.gbl...
I have a nagging suspicion that a dataset is not serializable
Yes it is - I do this all the time for smallish sets of data which (almost)
never changes e.g. countries, currencies etc...
--
Mark Rae
ASP.NET MVP
http://www.markrae.net

Mar 12 '08 #3
DataSets are XML, which is pretty much what serializable objects are
serialized to. :-)

For the record, a DataSet IS serializable.

--
Gregory A. Beamer
MVP, MCP: +I, SE, SD, DBA

*************************************************
| Think outside the box!
|
*************************************************
"Andrew Morton" <ak*@in-press.co.uk.invalidwrote in message
news:eU**************@TK2MSFTNGP06.phx.gbl...
Chris wrote:
>Makes sense now. Good ol' hindsight. So what other options do I have
if I want to put this query in a dataset, but retain the information
in the dataset after postbacks?

You can save data in the Session state (but I have a nagging suspicion
that a dataset is not serializable, so you'd have to figure out a way to
get the data into something that is, like an ArrayList).

Andrew

Mar 12 '08 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

5
by: Karl | last post by:
Hi C# experts, I am to C# and .NET. I am writing a database application using C# and Dataset. In Sql server, I have a Acount table which contains over 100,000 records. This table will be...
5
by: Jason | last post by:
I am having problems understanding how to access a datasource only once, fill a single dataset, and then reference that dataset multiple times through different user controls(ascx) found on the...
2
by: John Granade | last post by:
I'm looking for the best way to make a dataset available from multiple Windows forms. The dataset is created from an XML file. I have a main form (frmMain) that loads the dataset and reads the...
2
by: Rich Wallace | last post by:
I know datasets have been beaten to death in here, I have what is hopefully a simple question about the integrity of a dataset when used in an application. Scenario: User A and User B are...
3
by: Steve Amey | last post by:
Hi all I have created a strong DataSet using Visual Studio. I have been in to the DataSet's vb file to have a look at the code and see if I can add things to it. What I'm after is to create a...
2
by: Joe | last post by:
Hi I have a typed dataset and I want to add a method to modify a value in the datarow. I want to inherit from the class so if the XSDchanges I would lose my code when the class regenerates ...
6
by: mike11d11 | last post by:
I'm trying to create an application that will have multiple users working off a table on a SQL server. Since multi users will be updating different records at any given moment, how can i get those...
0
by: David Mayerovitch | last post by:
As an exercise in learning Visual Basic 2005, I am putting together a simple XML editor. I place on the form the objects DataGridView1 and DataSet1. ' Read an XML file into DataSet1:...
1
by: =?Utf-8?B?cmFuZHkxMjAw?= | last post by:
I'm working in Visual Studio 2005. I'm looking at two tables in the Data Set Designer. There's a relation between the two tables that lists 7 matching columns. Works great. One of the key...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.