Td Command Builder has a Data Adapter property and it must be initialized. NET Data Provider for Teradata will throw an exception when an application fails to initialize the required properties described above. Get Insert Command method will throw an "Invalid Operation Exception" when a) the Td Command Builder.
Data Adapter property is not set or b) Select Command (Data Adatper.
Fill(ds Production,"Companies"); String str Development SQL = "SELECT * FROM [Global].[dbo].[Companies] WHERE Company ID ='" str SQLDest Database "'"; Sql Data Adapter da Development = new Sql Data Adapter(str Development SQL, cn Development SQL); Data Set ds Development = new Data Set(); da Development. Each row in a Data Table has A Row State property that changes ONLY when the actual **row in the Data Table** is changed.
But How can you associate a Transaction with CUD commands given that you have no direct control over the Command generation?
We need to start by looking at the basic relationship between Td Command Builder class and Td Data Adapter class.
This application should have picked up the changes and inserted them into the other database.
I broke the code right before I set Data Row1 = Data Row2 and the two fields in Data Row1 did contain the expected values.
i'm rather new in this area so i'm trying to understand what you are saying.
There was definitely a change, I entered Null values in two of the fields in the database where the second server had values.
i have two questions: 1) What am I missing that is causing the script not to work?
2) With respect to a dataset how can I get at the value of a specific Row/Column? Ron Sql Connection cn Production SQL = new Sql Connection("Data Source=SQLSVR01; Integrated Security=SSPI; Initial Catalog=Master"); cn Production SQL.
Thanks for any help you can offer, Ron "Peter Bromberg [C# MVP]" RSH, I haven't looked carefully at your code sample, but I'd be willing to bet that the reason you aren't getting any updates is because the Row States of the rows in the second Data Adapter's table don't reflect any changes.
If you call the Get Changes method on the second Data Set, I bet you'll find you get an empty Data Table in it.
Peter -- Co-founder, developer portal: Blog: wrote: Hi, I have a situation in where i have two instances of SQL server, the first is our Production Environment, the second is our Development environment.