473,322 Members | 1,259 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,322 software developers and data experts.

Dataset Headaches

Hi all,
First of all, I am not trying to be the guy who comes in here shouting his
mouth off at Microsoft. However, ever sinse I started using typed datasets
in VS2005 I have been fighting with a recurring issue.

I will have a project open and be working in it just fine, when all of a
sudden when I try to do something in my dataset (either add a new query,
modify and existing one, etc.) I get a big fat error box on my screen
telling me that it couldn't find the connection string. Nothing has been
changed (manually) in the project in regards to the connection strings,
either in the web.config or the application settings.

Probably about 70% of the time, I can just drag a new table in the dataset
from the data explorer and that recreates the "lost" connection and
everything is fine for now. However, the other 30% of the time, I will try
that and it may appear to work at a glance, but then suddenly my code has
about 80 errors in it because the class that should have been generated by
that dataset has a random error in it. In the latest case I get "Error 101
Custom tool error: Failed to generate code. Unable to convert input xml file
content to a DataSet. Requested value 'My' was not found. Requested value
'My' was not found."

OK, so now my only option other than trying to hunt down the elusive "My"
that it's looking for, is to pull up the latest backup and try to merge my
changes into that one back when the dataset was still working. After going
through all this effort to get back to where I already was, I just need to
look forward to it happening all over again sometime in the near future.

I can't believe that I'm the only one going through this and it seems like
by now, there really should be some sort of resolution. I really like what
you are able to do using typed datasets, and have been pushing them at my
company ever sinse I started using them, but somedays the aggravation they
cause makes me want to go back to just doing everything manually.

OK, so thanks for letting me vent. Again, I'm not trying to "blame" anyone
in particular, I'm just trying to get a resolution. Does anyone have any
suggestions?

Thanks,
Matt
Jul 3 '07 #1
8 2095
OK, so thanks for letting me vent. Again, I'm not trying to "blame"
anyone
in particular, I'm just trying to get a resolution. Does anyone have any
suggestions?
You can use a strong typed Collection of Data Objects that persist
themselves to the database.

Jul 3 '07 #2
Mr. Arnold wrote:
>
>OK, so thanks for letting me vent. Again, I'm not trying to "blame"
anyone
in particular, I'm just trying to get a resolution. Does anyone have
any suggestions?

You can use a strong typed Collection of Data Objects that persist
themselves to the database.
Thank you for your suggestion. That doesn't really solve the problem at
hand, because I can't really go back and re-do the projects I'm
currently working on, but I may consider that for the future.
Jul 3 '07 #3
Mr. Arnold wrote:
>
>OK, so thanks for letting me vent. Again, I'm not trying to "blame"
anyone
in particular, I'm just trying to get a resolution. Does anyone have
any suggestions?

You can use a strong typed Collection of Data Objects that persist
themselves to the database.
Thank you for your suggestion. That doesn't really solve the problem at
hand, because I can't really go back and re-do the projects I'm
currently working on, but I may consider that for the future.
Jul 3 '07 #4

"Matt MacDonald" <ma******@hotmaill.comwrote in message
news:46**********@hotmaill.com...
Mr. Arnold wrote:
>>
>>OK, so thanks for letting me vent. Again, I'm not trying to "blame"
anyone
in particular, I'm just trying to get a resolution. Does anyone have
any suggestions?

You can use a strong typed Collection of Data Objects that persist
themselves to the database.

Thank you for your suggestion. That doesn't really solve the problem at
hand, because I can't really go back and re-do the projects I'm
currently working on, but I may consider that for the future.
Visual Paradigm's NHibernate

Jul 3 '07 #5
Hi Matt,

Rather than creating a dataset and dragging tables on to it with the VS 2005
designer, go back to the old VS 2003 method (using VS 2005) of

- Create a new component
- Drag your data adapters onto it
- Create a new dataset from the adapters.

This way, your dataset is independent of the underlying connection. It
really doesn't need a connection anyway. Just the adapters do.

I've heard that Microsoft is dropping this whole table adapter crap in VS
2008.

Jim

"Matt MacDonald" <ma******@hotmail.comwrote in message
news:%2****************@TK2MSFTNGP06.phx.gbl...
Hi all,
First of all, I am not trying to be the guy who comes in here shouting
his mouth off at Microsoft. However, ever sinse I started using typed
datasets in VS2005 I have been fighting with a recurring issue.

I will have a project open and be working in it just fine, when all of a
sudden when I try to do something in my dataset (either add a new query,
modify and existing one, etc.) I get a big fat error box on my screen
telling me that it couldn't find the connection string. Nothing has been
changed (manually) in the project in regards to the connection strings,
either in the web.config or the application settings.

Probably about 70% of the time, I can just drag a new table in the dataset
from the data explorer and that recreates the "lost" connection and
everything is fine for now. However, the other 30% of the time, I will
try that and it may appear to work at a glance, but then suddenly my code
has about 80 errors in it because the class that should have been
generated by that dataset has a random error in it. In the latest case I
get "Error 101 Custom tool error: Failed to generate code. Unable to
convert input xml file content to a DataSet. Requested value 'My' was not
found. Requested value 'My' was not found."

OK, so now my only option other than trying to hunt down the elusive "My"
that it's looking for, is to pull up the latest backup and try to merge my
changes into that one back when the dataset was still working. After
going through all this effort to get back to where I already was, I just
need to look forward to it happening all over again sometime in the near
future.

I can't believe that I'm the only one going through this and it seems like
by now, there really should be some sort of resolution. I really like
what you are able to do using typed datasets, and have been pushing them
at my company ever sinse I started using them, but somedays the
aggravation they cause makes me want to go back to just doing everything
manually.

OK, so thanks for letting me vent. Again, I'm not trying to "blame"
anyone in particular, I'm just trying to get a resolution. Does anyone
have any suggestions?

Thanks,
Matt

Jul 3 '07 #6
Again, thanks for the suggestion, but I'm kind of past the point where I can
just start my whole data layer over again. I need to be able to fix what I
have.

Thanks,
Matt

"Jim Rand" <ji*****@ix.netcom.comwrote in message
news:uk**************@TK2MSFTNGP03.phx.gbl...
Hi Matt,

Rather than creating a dataset and dragging tables on to it with the VS
2005 designer, go back to the old VS 2003 method (using VS 2005) of

- Create a new component
- Drag your data adapters onto it
- Create a new dataset from the adapters.

This way, your dataset is independent of the underlying connection. It
really doesn't need a connection anyway. Just the adapters do.

I've heard that Microsoft is dropping this whole table adapter crap in VS
2008.

Jim

"Matt MacDonald" <ma******@hotmail.comwrote in message
news:%2****************@TK2MSFTNGP06.phx.gbl...
>Hi all,
First of all, I am not trying to be the guy who comes in here shouting
his mouth off at Microsoft. However, ever sinse I started using typed
datasets in VS2005 I have been fighting with a recurring issue.

I will have a project open and be working in it just fine, when all of a
sudden when I try to do something in my dataset (either add a new query,
modify and existing one, etc.) I get a big fat error box on my screen
telling me that it couldn't find the connection string. Nothing has been
changed (manually) in the project in regards to the connection strings,
either in the web.config or the application settings.

Probably about 70% of the time, I can just drag a new table in the
dataset from the data explorer and that recreates the "lost" connection
and everything is fine for now. However, the other 30% of the time, I
will try that and it may appear to work at a glance, but then suddenly my
code has about 80 errors in it because the class that should have been
generated by that dataset has a random error in it. In the latest case I
get "Error 101 Custom tool error: Failed to generate code. Unable to
convert input xml file content to a DataSet. Requested value 'My' was not
found. Requested value 'My' was not found."

OK, so now my only option other than trying to hunt down the elusive "My"
that it's looking for, is to pull up the latest backup and try to merge
my changes into that one back when the dataset was still working. After
going through all this effort to get back to where I already was, I just
need to look forward to it happening all over again sometime in the near
future.

I can't believe that I'm the only one going through this and it seems
like by now, there really should be some sort of resolution. I really
like what you are able to do using typed datasets, and have been pushing
them at my company ever sinse I started using them, but somedays the
aggravation they cause makes me want to go back to just doing everything
manually.

OK, so thanks for letting me vent. Again, I'm not trying to "blame"
anyone in particular, I'm just trying to get a resolution. Does anyone
have any suggestions?

Thanks,
Matt


Jul 5 '07 #7


I believe you've fallen into the "Rapid Development" trap.

The quick drag and drop stuff can eventually screw you.
As you're finding out.
The development is quick. Maintenance sucks. Do yourself a favor and
develop a true DAL from the beginning.
In the long run, it'll save you.

I'd suggest:
Create the dataset independant of any underlying table adapter.

See
http://sholliday.spaces.live.com/Blog/cns!A68482B9628A842A!140.entry
for my example.

"Matt MacDonald" <ma******@hotmail.comwrote in message
news:%2****************@TK2MSFTNGP06.phx.gbl...
Hi all,
First of all, I am not trying to be the guy who comes in here shouting
his
mouth off at Microsoft. However, ever sinse I started using typed
datasets
in VS2005 I have been fighting with a recurring issue.

I will have a project open and be working in it just fine, when all of a
sudden when I try to do something in my dataset (either add a new query,
modify and existing one, etc.) I get a big fat error box on my screen
telling me that it couldn't find the connection string. Nothing has been
changed (manually) in the project in regards to the connection strings,
either in the web.config or the application settings.

Probably about 70% of the time, I can just drag a new table in the dataset
from the data explorer and that recreates the "lost" connection and
everything is fine for now. However, the other 30% of the time, I will
try
that and it may appear to work at a glance, but then suddenly my code has
about 80 errors in it because the class that should have been generated by
that dataset has a random error in it. In the latest case I get "Error
101
Custom tool error: Failed to generate code. Unable to convert input xml
file
content to a DataSet. Requested value 'My' was not found. Requested value
'My' was not found."

OK, so now my only option other than trying to hunt down the elusive "My"
that it's looking for, is to pull up the latest backup and try to merge my
changes into that one back when the dataset was still working. After
going
through all this effort to get back to where I already was, I just need to
look forward to it happening all over again sometime in the near future.

I can't believe that I'm the only one going through this and it seems like
by now, there really should be some sort of resolution. I really like
what
you are able to do using typed datasets, and have been pushing them at my
company ever sinse I started using them, but somedays the aggravation they
cause makes me want to go back to just doing everything manually.

OK, so thanks for letting me vent. Again, I'm not trying to "blame"
anyone
in particular, I'm just trying to get a resolution. Does anyone have any
suggestions?

Thanks,
Matt


Jul 5 '07 #8
I had a similar issue before. My post is at http://tinyurl.com/2p49qo
In my case, the issue was caused by copying a datatable from one xsd to
another. Once the problem occurs, there seems to be no way of fixing it.

I got tired of fixing the auto generated code, so in the end I just created
a new dataset. I let the wizard to most of the initial work, then pasted any
new tables one field at a time.
Likewise, I just copied the data adapter SQL statements - I made sure not to
copy the data adapter.
Even if you use Sourcesafe, like I do, restoring prior versions of the xsd
will not fix the project.

I've stuck to this technique since, and I get a lot less issues.
Not what you want to hear, I'm sure! However, it doesn't take that long once
you start. Plus you get stick with your current approach, no need to rewrite
the rest of the project.

Also, I'd recommend starting a brand new project - the connection string
seems to be stored in several places. Add your existing forms to the new
project. May seem a bit of paranoia , but better than going to all that
trouble and then finding the project still has problems.

Like you, I like using typed datasets, but it is a very fragile technology.
Vayse

"Matt MacDonald" <ma******@hotmail.comwrote in message
news:%2****************@TK2MSFTNGP06.phx.gbl...
Hi all,
First of all, I am not trying to be the guy who comes in here shouting
his mouth off at Microsoft. However, ever sinse I started using typed
datasets in VS2005 I have been fighting with a recurring issue.

I will have a project open and be working in it just fine, when all of a
sudden when I try to do something in my dataset (either add a new query,
modify and existing one, etc.) I get a big fat error box on my screen
telling me that it couldn't find the connection string. Nothing has been
changed (manually) in the project in regards to the connection strings,
either in the web.config or the application settings.

Probably about 70% of the time, I can just drag a new table in the dataset
from the data explorer and that recreates the "lost" connection and
everything is fine for now. However, the other 30% of the time, I will
try that and it may appear to work at a glance, but then suddenly my code
has about 80 errors in it because the class that should have been
generated by that dataset has a random error in it. In the latest case I
get "Error 101 Custom tool error: Failed to generate code. Unable to
convert input xml file content to a DataSet. Requested value 'My' was not
found. Requested value 'My' was not found."

OK, so now my only option other than trying to hunt down the elusive "My"
that it's looking for, is to pull up the latest backup and try to merge my
changes into that one back when the dataset was still working. After
going through all this effort to get back to where I already was, I just
need to look forward to it happening all over again sometime in the near
future.

I can't believe that I'm the only one going through this and it seems like
by now, there really should be some sort of resolution. I really like
what you are able to do using typed datasets, and have been pushing them
at my company ever sinse I started using them, but somedays the
aggravation they cause makes me want to go back to just doing everything
manually.

OK, so thanks for letting me vent. Again, I'm not trying to "blame"
anyone in particular, I'm just trying to get a resolution. Does anyone
have any suggestions?

Thanks,
Matt

Jul 9 '07 #9

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

Similar topics

3
by: Bill C. | last post by:
Hi, I've got a simple console app that just reads an XML file into a DataSet then prints out a description of each table in the DataSet, including column names and row values for each column. ...
1
by: Andy | last post by:
Hello, I have a WebService that sends a client a DataSet as XML (I use a DataSet.GetXml to get the XML). The DataSet is filled by a DataAdapter in the WebService. The client coverts the XML Back...
5
by: Mike | last post by:
I need to expand the DataSet class by inheriting from it and adding functions that work on the data in the tables. However, since I can't upcast how can I get my base DataSet object assigned an...
2
by: John Holmes | last post by:
I have a web interface where the user types in ID's one at a time. After an ID is typed in, a button is clicked and the button click event has code that does a query and returns a data reader and...
4
by: Rob | last post by:
Hi, I've been going at this for a few days and can't see the problem. Does anyone see a problem with this code? I have a call to a function that returns a dataset and when I assign values to...
2
by: Wayne Wengert | last post by:
I have a VB App (VSNET 2003) in which, during form load, I create a dataset (ds1) and then populate a datagrid by binding to the dataset. That works fine. The form has a button which, when clicked,...
22
by: Arne | last post by:
How do I pass a dataset to a webservices? I need to submit a shoppingcart from a pocket PC to a webservice. What is the right datatype? II have tried dataset as a datatype, but I can't get it to...
1
by: matt | last post by:
hello, i have a web app that allows users to query our oracle db and produce a dataset of report data. they then have the option to serialize this data and store it in the database. later, then...
8
by: Matt MacDonald | last post by:
Hi all, First of all, I am not trying to be the guy who comes in here shouting his mouth off at Microsoft. However, ever sinse I started using typed datasets in VS2005 I have been fighting with a...
5
TheServant
by: TheServant | last post by:
Hey guys, I am trying to generate a table automatically, but I am having headaches using foreach loops: $raw_user_rankings = mysql_query("SELECT user_id, user_name, user_clan_id, user_pop,...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
1
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...

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.