I try to use ODAC 6.x to create an application that uses DataSnap.
TOraSession TOraQuery TDataSetProvider ClientDataSet1 / ClientDataSet 2
The ClientDataSets have different CommandText properies. Say CDS1 has "select * from a" and CDS2 has "select * from b".
Now I do the following:
CDS1.active:=true;
CDS2.active:=true;
// After that the TOraQuery.SQL.Text is "select * from b".
CDS1.Insert;
CDS1.Fields ... := 1; // edit the desired fields
CDS1.Post;
OraQuery.sql.text := cds1.CommandText; // This is because the provider gets the table name from the DataSet.
CDS1.ApplyUpdates(0);
Now the Provider gets table b for update instead of table a which I have set in the sql.text.
I have investigated your source and the problem seems to be in DBAccess.pas there you should change PSGetTableName to first serve the TableNameFromSQL instead of the saved FOldTableName.
Hope this helps.