How to modify an existing schema for a strongly typed dataset
am 03.04.2008 21:21:36 von socamb
all,
I need to do what seemes a simple task, but i am stuck. I have a
column in my database i need to change from 7 chars to 10 chars. I
have a number of strongly typed datasets in my system that use this
table.
I attempted to edit the xsd file in the designer and changed the 7 to
a 10.
But the underlaying class file did not get updated. When i searched
for the column i need to change it still was set to 7.
Then I attempted to run the "Table Adapter Configuration Widard". This
actually broke the application and it would not compile. I then
noticed that duplicate colmns appeared in the table in the dataset.
For example there was ProjectId and ProjectId1. ProjectId1 did not
exist before.
I hope i am missing something simple here.
I did change the code generated files to widen the columns in question
and the app seemed to work ok, but i am sure this is not the prefered
way to go,
any help would be appreciated.
Re: How to modify an existing schema for a strongly typed dataset
am 03.04.2008 21:55:38 von NoSpamMgbworld
You have to regen the underlying classes or edit each one. There is a way to
do it from the right click menu in the soultion explorer. In VS 2005, it was
(for some reason) named custom tool. That may have been fixed in one of
patches, however.
--
Gregory A. Beamer
MVP, MCP: +I, SE, SD, DBA
Subscribe to my blog
http://gregorybeamer.spaces.live.com/lists/feed.rss
or just read it:
http://gregorybeamer.spaces.live.com/
*************************************************
| Think outside the box!
|
*************************************************
"socamb" wrote in message
news:b3950893-d10b-4bf3-9fb0-596114315ffb@a22g2000hsc.google groups.com...
> all,
>
> I need to do what seemes a simple task, but i am stuck. I have a
> column in my database i need to change from 7 chars to 10 chars. I
> have a number of strongly typed datasets in my system that use this
> table.
>
> I attempted to edit the xsd file in the designer and changed the 7 to
> a 10.
>
> But the underlaying class file did not get updated. When i searched
> for the column i need to change it still was set to 7.
>
> Then I attempted to run the "Table Adapter Configuration Widard". This
> actually broke the application and it would not compile. I then
> noticed that duplicate colmns appeared in the table in the dataset.
> For example there was ProjectId and ProjectId1. ProjectId1 did not
> exist before.
>
> I hope i am missing something simple here.
>
> I did change the code generated files to widen the columns in question
> and the app seemed to work ok, but i am sure this is not the prefered
> way to go,
>
> any help would be appreciated.
Re: How to modify an existing schema for a strongly typed dataset
am 03.04.2008 23:14:49 von socamb
On Apr 3, 3:55=A0pm, "Cowboy \(Gregory A. Beamer\)"
wrote:
> You have to regen the underlying classes or edit each one. There is a way =
to
> do it from the right click menu in the soultion explorer. In VS 2005, it w=
as
> (for some reason) named custom tool. That may have been fixed in one of
> patches, however.
>
> --
> Gregory A. Beamer
> MVP, MCP: +I, SE, SD, DBA
>
> Subscribe to my bloghttp://gregorybeamer.spaces.live.com/lists/feed.rss
>
> or just read it:http://gregorybeamer.spaces.live.com/
>
> *************************************************
> | Think outside the box!
> |
> *************************************************"socamb"
m> wrote in message
>
> news:b3950893-d10b-4bf3-9fb0-596114315ffb@a22g2000hsc.google groups.com...
>
>
>
> > all,
>
> > I need to do what seemes a simple task, but i am stuck. I have a
> > column in my database i need to change from 7 chars to 10 chars. I
> > have a number of strongly typed datasets in my system that use this
> > table.
>
> > I attempted to edit the xsd file in the designer and changed the 7 to
> > a 10.
>
> > But the underlaying class file did not get updated. When i searched
> > for the column i need to change it still was set to 7.
>
> > Then I attempted to run the "Table Adapter Configuration Widard". This
> > actually broke the application and it would not compile. I then
> > noticed that duplicate colmns appeared in the table in the dataset.
> > For example there was ProjectId and ProjectId1. ProjectId1 did not
> > exist before.
>
> > I hope i am missing something simple here.
>
> > I did change the code generated files to widen the columns in question
> > and the app seemed to work ok, but i am sure this is not the prefered
> > way to go,
>
> > any help would be appreciated.- Hide quoted text -
>
> - Show quoted text -
Thanks, but i tried
right click on the xsd file and "run custom tool".
It did not do anything that i could see.