Re: Syntax error (missing operator) when delete with Commandbuider



Hi Cor
Call me mister stupid but I'm still have trouble with it.
I was already using AcceptChanges etc on the second copy database but not on
the original.
So I decided it would be best not to copy the database as this seems a waste
of time anyway when I already have access the the dataset as a parameter of
the dataStorage class that I mentioned in my previous post.
I then added the Accept changes etc and it still failed.
I did notice one thing.
There are 9 tables in total in the database and I use a seporate dataAdapter
for each of them. Two of the tables that are earlyer in the routine that
updates them are deleting and updateing correctly.
So I'm a bit confused why it works on these and fails on 2 others. (Some
tables have nothing in).


--
All the best
Hawkmoth


"Cor Ligthert" wrote:

> Hawkmoth,
>
> For this is acceptchanges is for, when you know that your dataset is correct
> processed, than you can do an acceptchanges on the copy of that as well.
> Which deletes the datarows which are marked as deleted actually and does the
> actual changes in the dataset and set all rowstates to "not changed".
>
> I hope this clears it?
>
> Cor
>
>
>
.



Relevant Pages

  • Re: duplicate records being recorded
    ... do I change my UpdateAnswers sub to just AcceptChanges from the dataset? ... the program updates the database just from adding rows to the dataset. ...
    (microsoft.public.dotnet.languages.vb)
  • Re: Update records in a Dataset... How? Please help
    ... You should NEVER call AcceptChanges before calling Update because if you do ... then the changes you have made will not be committed back to the database. ... have their RowState set back to Unchanged so no data will be reconciled with ...
    (microsoft.public.dotnet.framework.aspnet)
  • Re: DataAdapter.Update
    ... Update calls AcceptChanges on each row as it updates them. ... I begin a transaction on my connection and attempt to update ... rows as one transaction to the database. ... but my second row fails due to a business ...
    (microsoft.public.dotnet.framework.adonet)
  • Re: Datagrids
    ... "Programming Visual Basic.net" by Francesco Balena (first edition). ... warned not to ever use the AcceptChanges command, ... I cannot answer yes or no on your question, because when you do the database ... I would try it by refreshing the datagrid. ...
    (microsoft.public.dotnet.languages.vb)
  • Re: Refresh DataSet - please Help Me :-(
    ... >And than to get more help it probably better to ask this in the newsgroup ... Firstly let me say I agree with Cor, the best approach to a problem ... the usual approach to refreshing a dataset is to have one ... Update the database with any changes made. ...
    (microsoft.public.dotnet.languages.vb)

Loading