Connecting Tech Pros Worldwide Forums | Help | Site Map

anyone using CommandBuilder to generate update logic at runtime?

Jason Shohet
Guest
 
Posts: n/a
#1: Nov 15 '05
What we've done so far in our web applications:
1. We have no datasets dragged-and-dropped in Visual Studio. They are all
defined in the code, generated at runtime.
2. when a user updates or hits a 'delete' button next to a row in a
datagrid, we call a webservice. In there, we coded insert, update & delete
functionality.

I'm tired of seeing all that update logic in our code. I am looking for a
way to have .NET generate its own update / delete / insert statements. BUT,
I don't want to use that DataAdapter Configuration Wizard because if we
change around a field in the db, everything breaks and there's too much
going on under the hood to fix it. If a query changes in our dataset, I
would like the update logic to automatically change as well. I've been
looking at CommandBuilder -- is this something good to use? In order to use
it, do I need to define the dataset at Design Time (visually drag it on to
the web service etc) ?

Any other suggestions would be appreciated
TY
Jason Shohet



Nick Harris
Guest
 
Posts: n/a
#2: Nov 15 '05

re: anyone using CommandBuilder to generate update logic at runtime?


CommandBuilder isn't going to do this automatically. If you find it does,
let me know. :-) I'd use the DA Config Wiz. If you change a field, go back
through the wiz and tell it to regenerate. If you have classes that use
this as a independent object, it should be simple to go back and add/remove
the edits you make to that particular table.

Nick Harris, MCSD
http://www.VizSoft.net


" Jason Shohet" <ash477@hotmail.com> wrote in message
news:O1fhdyS1DHA.3116@TK2MSFTNGP11.phx.gbl...[color=blue]
> What we've done so far in our web applications:
> 1. We have no datasets dragged-and-dropped in Visual Studio. They are[/color]
all[color=blue]
> defined in the code, generated at runtime.
> 2. when a user updates or hits a 'delete' button next to a row in a
> datagrid, we call a webservice. In there, we coded insert, update &[/color]
delete[color=blue]
> functionality.
>
> I'm tired of seeing all that update logic in our code. I am looking for a
> way to have .NET generate its own update / delete / insert statements.[/color]
BUT,[color=blue]
> I don't want to use that DataAdapter Configuration Wizard because if we
> change around a field in the db, everything breaks and there's too much
> going on under the hood to fix it. If a query changes in our dataset, I
> would like the update logic to automatically change as well. I've been
> looking at CommandBuilder -- is this something good to use? In order to[/color]
use[color=blue]
> it, do I need to define the dataset at Design Time (visually drag it on to
> the web service etc) ?
>
> Any other suggestions would be appreciated
> TY
> Jason Shohet
>
>[/color]


Closed Thread