Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > ASP .Net > Typed DataSet, Refresh in VS 2005?

Reply
Thread Tools

Typed DataSet, Refresh in VS 2005?

 
 
Liming
Guest
Posts: n/a
 
      04-21-2006
Hi,

I designed a few DataSet Tables in the typed dataset dsigner. Recently,
I encountered an error saying

Failed to enable constraints. One or more rows contain values violating
non-null, unique, or foreign-key constraints.

I didn't have any relations or non null values in the table, so I
didn't know what was going on. I debugged by manually query the same
sql and injected it into the typed datatable. When errors happen, I
loop through each row in errors and the columns in error and found out
that one my column's value exceeded the maxium length allowed. I
printed out the maxium length, it was "10" when in database, it's "50".

The issue here is, originally when the data table was added into the
designer, db had a value "10".. I changed it later to "50".. but the
dataset designer did not reflect this new change and now an error was
thrown (if I didn't know how to manually loop through the error rows, I
wouldn't even know what happened)

I'm wondering how do you tell VS2005 designer to refresh its datatable
definition? I don't see a "refresh" option or anything. (right now, I
just go manually update it) But it would be nice to have a refersh
option.

In addition, why that when I was inserting, no error happened? How do
you make it so that it auto truncate anystring that exceed the allowed
maxlenght?

Thanks.

 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
mix statically typed with dynamically typed Yingjie Lan Python 4 01-29-2010 08:50 AM
JSP: Session parameters vanish on refresh. How do I keep them on refresh? Per Magnus L?vold Java 1 10-08-2004 02:52 PM
How can I add a row from a typed datatable to another instance of that typed datatable? Ersin Gençtürk ASP .Net 1 10-06-2004 01:11 PM
How do i refresh a datagrid from a pop up window without having to refresh the whole page? Pkenty ASP .Net Web Controls 0 05-28-2004 07:06 AM
Problem with refresh button breaking automatic refresh brian lanning ASP .Net 0 07-29-2003 07:57 PM



Advertisments