Solved

Concurrency violation: the UpdateCommand affected 0 of the expected 1 records - TableAdapter.Update

Posted on 2008-10-02
2
1,092 Views
Last Modified: 2012-05-05
I get the following error message when I execute the below lines.  Any suggestions on what is wrong or how to troubleshoot this.

Me.QuoteReqBindingSource.EndEdit()
Me.QuoteReqTableAdapter.Update(Me.DsetQuote_Entry.QuoteReq)

Concurrency violation: the UpdateCommand affected 0 of the expected 1 records
0
Comment
Question by:jaydwest
2 Comments
 
LVL 22

Expert Comment

by:RedKelvin
ID: 22631166
Hi,
2 common reasons are
1. Editing an Auto Increment column.
2. Updating a row of a table which does not have a primary key.

RedK
0
 

Accepted Solution

by:
jaydwest earned 0 total points
ID: 22633349
Thanks for your help.  I did find the issue.  I was closing a connection object in the FInally block but declaring it in the Try Block.  The connection needed to be declared before the Try Statement.  
0

Featured Post

Courses: Start Training Online With Pros, Today

Brush up on the basics or master the advanced techniques required to earn essential industry certifications, with Courses. Enroll in a course and start learning today. Training topics range from Android App Dev to the Xen Virtualization Platform.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
vb.net - How to check if current user is an administrator? 6 45
vb.net checkbox 7 46
VB.NET (2008) - Refactoring Question 2 19
Modal Popup Extender control 1 18
Article by: Kraeven
Introduction Remote Share is a simple remote sharing tool, enabling you to see, add and remove remote or local shares. The application is written in VB.NET targeting the .NET framework 2.0. The source code and the compiled programs have been in…
Introduction When many people think of the WebBrowser (http://msdn.microsoft.com/en-us/library/2te2y1x6%28v=VS.85%29.aspx) control, they immediately think of a control which allows the viewing and navigation of web pages. While this is true, it's a…
This video shows how to use Hyena, from SystemTools Software, to bulk import 100 user accounts from an external text file. View in 1080p for best video quality.
With Secure Portal Encryption, the recipient is sent a link to their email address directing them to the email laundry delivery page. From there, the recipient will be required to enter a user name and password to enter the page. Once the recipient …

785 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question