G
Guest
I am getting a concurrency violation on an update statement, which is using SQL (not stored procedure). The exception occured only when some records were processed. Ie. same code worked fine for another set of records. Below is the exception text. Any Idea what is happening.
Thanks,
Rajesh Abraham Chacko.
************** Exception Text **************
System.Data.DBConcurrencyException: Concurrency violation: the UpdateCommand affected 0 records.
at System.Data.Common.DbDataAdapter.Update(DataRow[] dataRows, DataTableMapping tableMapping)
at System.Data.Common.DbDataAdapter.Update(DataRow[] dataRows)
at Itep.DbData.DbUtils.UpdateNewStudents(DataRow[] rwsStudents) in c:\itep.net\itepdbdata\dbdata\dbutils.cs:line 170
at Itep.TrackingSyncBis.BisUtils.ImportUsers(DataRow[]
rwStudentsToImport) in c:\itep.net\trackingsyncbis\trackingsyncbis\bisutils.cs:line 241
at Itep.TrackingSync.frmTrackingSync.btnImportToAd_Click(Object sender, EventArgs e) in c:\itep.net\iteptrackingsync0304\trackingsync.cs:line 911
at System.Windows.Forms.Control.OnClick(EventArgs e)
at System.Windows.Forms.Button.OnClick(EventArgs e)
at System.Windows.Forms.Button.OnMouseUp(MouseEventArgs mevent)
at System.Windows.Forms.Control.WmMouseUp(Message& m, MouseButtons button, Int32 clicks)
at System.Windows.Forms.Control.WndProc(Message& m)
at System.Windows.Forms.ButtonBase.WndProc(Message& m)
at System.Windows.Forms.Button.WndProc(Message& m)
at System.Windows.Forms.ControlNativeWindow.OnMessage(Message& m)
at System.Windows.Forms.ControlNativeWindow.WndProc(Message& m)
at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)
Thanks,
Rajesh Abraham Chacko.
************** Exception Text **************
System.Data.DBConcurrencyException: Concurrency violation: the UpdateCommand affected 0 records.
at System.Data.Common.DbDataAdapter.Update(DataRow[] dataRows, DataTableMapping tableMapping)
at System.Data.Common.DbDataAdapter.Update(DataRow[] dataRows)
at Itep.DbData.DbUtils.UpdateNewStudents(DataRow[] rwsStudents) in c:\itep.net\itepdbdata\dbdata\dbutils.cs:line 170
at Itep.TrackingSyncBis.BisUtils.ImportUsers(DataRow[]
rwStudentsToImport) in c:\itep.net\trackingsyncbis\trackingsyncbis\bisutils.cs:line 241
at Itep.TrackingSync.frmTrackingSync.btnImportToAd_Click(Object sender, EventArgs e) in c:\itep.net\iteptrackingsync0304\trackingsync.cs:line 911
at System.Windows.Forms.Control.OnClick(EventArgs e)
at System.Windows.Forms.Button.OnClick(EventArgs e)
at System.Windows.Forms.Button.OnMouseUp(MouseEventArgs mevent)
at System.Windows.Forms.Control.WmMouseUp(Message& m, MouseButtons button, Int32 clicks)
at System.Windows.Forms.Control.WndProc(Message& m)
at System.Windows.Forms.ButtonBase.WndProc(Message& m)
at System.Windows.Forms.Button.WndProc(Message& m)
at System.Windows.Forms.ControlNativeWindow.OnMessage(Message& m)
at System.Windows.Forms.ControlNativeWindow.WndProc(Message& m)
at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)