Feng
Thu Oct 06 17:14:01 CDT 2005
Don't warry. I figured it out.
Thank you so much for your help!
"Feng" wrote:
> Thanks Sahil for your response. For some reason, I couldn't find the
> "RowUpdating" event of a datatable class. Do you mean RowChanging? But that's
> not what need. It's too early in timing. I want to capture the SQL string
> RIGHT BEFORE it is sent to the database.
>
> Any idea?
>
> Thanks again!
>
> Feng
>
> "Sahil Malik [MVP]" wrote:
>
> > Feng,
> >
> > Yes there is a way. Right at the RowUpdating event of the datatable being
> > updated, check the
> >
> > DbDataAdapter.InsertCommand.CommandText
> > DbDataAdapter.UpdateCommand.CommandText
> > DbDataAdapter.DeleteCommand.CommandText
> >
> >
> > --
> >
> > - Sahil Malik [MVP]
> > ADO.NET 2.0 book -
> >
http://codebetter.com/blogs/sahil.malik/archive/2005/05/13/63199.aspx
> > ----------------------------------------------------------------------------
> >
> >
> > "Feng" <Feng@discussions.microsoft.com> wrote in message
> > news:3FDE2836-A87F-4B8C-913E-6F5D35942ED2@microsoft.com...
> > > Hi,
> > >
> > > We are having a major debugging problem here and would like to take
> > > advices
> > > from anyone.
> > >
> > > In our app, we need to update our dataset using DbDataAdapter against
> > > Oracle
> > > database. Once we have issues, like invalid data or something like that,
> > > the
> > > update will fail but only with limited returned message. It would be
> > > extramly
> > > helpful if we could somehow capture the SQL text that built by the
> > > ADO.Net,
> > > right before or after the Update is called. Is there a way to do that?
> > >
> > > Thanks
> > >
> > > Feng
> >
> >
> >