Login ProductsSalesSupportDownloadsAbout |
Home » Technical Support » ElevateDB Technical Support » Support Forums » ElevateDB General » View Thread |
Messages 1 to 2 of 2 total |
.Net TableAdapter.Update fails |
Fri, Nov 20 2009 12:22 PM | Permanent Link |
"James Relyea" | I'm seeing a potential problem with the EDB .Net 2.03B6 client.
This fails with a "connection not open" error: N using ( JBR.SimplyA_Z.PhNums.Common.dsPhNumsTableAdapters.taPhNums = taNums =3D new = JBR.SimplyA_Z.PhNums.Common.dsPhNumsTableAdapters.taPhNums() ) { Elevate.ElevateDB.Data.EDBConnection edbConn =3D new = Elevate.ElevateDB.Data.EDBConnection(); edbConn.ConnectionString =3D "blahblahblahblah"; edbConn.Open(); taNums.Connection =3D edbConn; taNums.Update( DataSetName.TheTableName);} I go as far as verifying the connection state is open on the table = adapter @ the Update() line. There's no references to the EDB data = provider, so the exception message is throwing me a bit.=20 This is the complete exception: {"Connection is not open"} [System.InvalidOperationException]: {"Connection is not open"} Data: {System.Collections.ListDictionaryInternal} HelpLink: null InnerException: null Message: "Connection is not open" Source: "System.Data" StackTrace: " at = System.Data.Common.DbDataAdapter.UpdatedRowStatusErrors(RowUpdatedEventAr= gs rowUpdatedEvent, BatchCommandInfo[] batchCommands, Int32 = commandCount)\r\n at = System.Data.Common.DbDataAdapter.UpdatedRowStatus(RowUpdatedEventArgs = rowUpdatedEvent, BatchCommandInfo[] batchCommands, Int32 = commandCount)\r\n at System.Data.Common.DbDataAdapter.Update(DataRow[] = dataRows, DataTableMapping tableMapping)\r\n at = System.Data.Common.DbDataAdapter.UpdateFromDataTable(DataTable = dataTable, DataTableMapping tableMapping)\r\n at = System.Data.Common.DbDataAdapter.Update(DataTable dataTable)\r\n at = JBR.SimplyA_Z.PhNums.Common.dsPhNumsTableAdapters.taPhNums.Update(tPhNums= DataTable dataTable) in = D:\\JBR\\SimplyA-Z\\Application\\PhNums\\PhNums.Common\\dsPhNums.Designer= ..cs:line 1454\r\n at JBR.SimplyA_Z.PhNums.Biz.PhNums.AddPhNum(dsPhNums& = DS)" TargetSite: {Int32 = UpdatedRowStatusErrors(System.Data.Common.RowUpdatedEventArgs, = BatchCommandInfo[], Int32)} I'm working on using a DataAdapter as a work around for now. Does anyone = have any suggestions? I don't see much that I can change because the = connections already open. Thanks jr |
Fri, Nov 20 2009 2:31 PM | Permanent Link |
Tim Young [Elevate Software] Elevate Software, Inc. timyoung@elevatesoft.com | James,
<< I'm seeing a potential problem with the EDB .Net 2.03B6 client. >> Per email, please send me a sample project that reproduces this. I suspect that the problem is similar to the stored procedures issue with updates, i.e. VS is simply requiring a specific construction of the underlying command or procedure. -- Tim Young Elevate Software www.elevatesoft.com |
This web page was last updated on Tuesday, April 30, 2024 at 03:55 PM | Privacy PolicySite Map © 2024 Elevate Software, Inc. All Rights Reserved Questions or comments ? E-mail us at info@elevatesoft.com |