473,372 Members | 1,338 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,372 software developers and data experts.

Concurrency Violation: the Delete Command Affected 0 records

What I am trying to do is wipe information from a number of tables after
submission to a SQL server database. Of the 6 tables I am trying to wipe I
have had no issues with 5 of them. Multiple entries can be made and they
are then deleted. For one of the tables though, I keep getting the error
Concurrency Violation: the deleted command affected 0 records. the code is
as follows.

Dim myindex3 as Short
Dim mydefault3 as Integer
mydefault3 = 0
myindex3 = DataSet51.evidence.Rows.Count
If myindex3 <> 0 Then
Do Until mydefault3 = myindex3
mydefault3 = mydefault3 + 1
End If
----this is where the error is thrown

We also checked to make sure that the fill command on page load is filling
the dataset51 correctly and that is indeed the case, since we print out the
value to the screen and can see that the count is functioning properly.
Any help on this matter would be very much appreciated.

Message posted via http://www.dotnetmonster.com
Nov 21 '05 #1
1 4543

I am not sure if it helps, however I think you are after the remove wich
removes a datarow, while the delete set only the rowstate to "deleted".


Read the explaining text on this page and than it will hopefully be clear.
Did you know that using long cost more memory (processing) than using
integer. VBnet is optimed for integer.

I hope this helps?

Nov 21 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

by: Charlie Williams | last post by:
I am having difficulty performing updates and deletions on an Access database using the Update() method of the OleDBDataAdapter. I can insert rows without a problem, but I get a concurrency...
by: Suzanne | last post by:
Hi All I'm having problems getting my data adapter to throw a concurrency exception with an INSERT command. I want to throw a concurrency exception if an attempt is made to enter a row into...
by: nick | last post by:
I'm having trouble updating from a datagrid. It's says "Concurrency violation: the UpdateCommand affected 0 records", though I can't see how it's related to "concurrency". I can insert and delete...
by: Geraldine Hobley | last post by:
Hello, I have a problem whereby I have a datagrid that is bound to a dataTable. However occassionally when I edit the datagrid I get the following message. Concurrency Violation the update...
by: mivey4 | last post by:
Okay, The problem is that I have an Access Database that has the following fields: EmpID - Autonumber (PrimaryKey) AccountID - Text IssueReported - Memo DateOpened ...
by: BobAchgill | last post by:
Do you know why this error might be happening? Maybe it is because I have two data adapters open on the same MDB file?? If this is the problem... how can I keep them from disturbing each other?...
by: Vayse | last post by:
In my save code, most of items save fine. But sometimes I get a concurrency violation message. "Concurrency violation: the UpdateCommand affected 0 of the expected 1 records." It happens on the...
by: Miriam | last post by:
Hello, I got the error "Concurrency violation: the UpdateCommand affected 0 records" while updating some records in the Windows Application. I am using VB.net in VS 2003 and the backend is...
by: John | last post by:
Hi I had a working vs 2003 application with access backend. I added a couple fields in a table in access db and then to allow user to have access to these fields via app I did the following; ...
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...
by: ryjfgjl | last post by:
In our work, we often need to import Excel data into databases (such as MySQL, SQL Server, Oracle) for data analysis and processing. Usually, we use database tools like Navicat or the Excel import...
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.