Hello,
I receive an error message when I try to Push data that the table is not tracked. However, when I try to turn on the tracking option it gives me an error that the table is a multi query table and therefore cannot be tracked. Here is my code to Pull the table.
string TPDAPull = string.Format("SELECT Table1.Field1,Table1.Field2, Table1.Field3, Table1.Field4, from Table1 Left Join Table2 on Table1.Field1 =Table2.Field1 WHERE Table2.Field12='{0}'", this.FindWorker(var));
rda.Pull("Table1", TPDAPull, rdaOleDbConnectString, RdaTrackOption.TrackingOn);
This table does not have a primary key. I was wondering what can I do in this situation? I do not want to Pull the whole table. Any suggestions would be greatly appreciated. I am working in VS 2005, NCF2.0, C#, WM5.0.
Thanks in advance!
What about using a subquery?|||You could make a single table view and pull this instead (but the view must reference only ONE table).
A primary is required if using RDA tracking. See http://msdn2.microsoft.com/en-us/library/ms172971.aspx
"A primary key must be defined on the updatable recordset returned by the SELECT statement. "
|||
Thank you Erik and Graham for your replies. Erik I was wondering, can I use SubmitSql instead of Rda.push? The problem I am encountering is that I cannot change the schema of the SQL Server 2000 tables. Please let me know.
Thanks in advance!
|||Yes, of course you could use SubmitSQL, it can be used for any SQL statement that does not return rows (INSERT, EXEC sproc, UPDATE etc.)|||Thanks Erik! I appreciate all your help.
No comments:
Post a Comment