• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 1098
  • Last Modified:

How to post clientdataset's delta via difference provider?

I want to get data from one provider while post the changed with another. How to do that?

Thanks advance.
0
qlwuu
Asked:
qlwuu
1 Solution
 
swift99Commented:
The Delta can be assigned to a variant, and then that variant assigned to the Data property of another clientdataset (Call it DeltaDataset).

At that point in time you can traverse the DeltaDataset and perform the operations from each row based on its status on the detination dataset.

I think that this is what you areasking for.  If not, please clarify your problem somewhat.
0
 
qlwuuAuthor Commented:
Thanks. :-)

I want to get and post data using "common" provider.In server site there are two provider with two adoDataSet connected.Client site get data with such interace:

function GetData(QueryID: String; Params: OleVariant): OleVariant;

Server lookup sql script corresponding the QueryID and set the commandtext of "Select" adoDataSet and return data like this:
 
SelectDataSet.Close;
SelectDataSet.CommandText := GetSQLScript(QueryID);
SelectDataSet.Open;
Result := SelectProvider.Data;

The code work fine.So let's go on, below is the code post delta(ResolveToDataSet=False):

UpdateDataSet.Close;
UpdateDataSet.CommandText := GetSQLScript(QueryID);

//here raise the exception
//"missing data provider or data packet"
UpdateProvider.ApplyUpdates(vDelta, 0, iErrCount);

I also try to :
evaluate tablename in provider's OnGetTableName event, nothing change...
set ResolveToDataSet=True and open UpdateDataSet before post data, it dosen't work...





0
 
CleanupPingCommented:
qlwuu:
This old question needs to be finalized -- accept an answer, split points, or get a refund.  For information on your options, please click here-> http:/help/closing.jsp#1 
EXPERTS:
Post your closing recommendations!  No comment means you don't care.
0
 
snehanshuCommented:
Hi!
No comment has been added lately and this question is therefore classified abandoned.

If asker wishes to close the question, then refer to
http://www.experts-exchange.com/help/closing.jsp

Otherwise, I will leave a recommendation in the Cleanup topic area that this question is:

PAQ'd and pts refunded

Please leave any comments here within the next seven days. It is assumed that any participant not responding to this request is no longer interested in its final disposition.

PLEASE DO NOT ACCEPT THIS COMMENT AS AN ANSWER!

...Snehanshu
EE Cleanup Volunteer
0
 
moduloCommented:
PAQed, with points refunded (50)

modulo
Community Support Moderator
0

Featured Post

Free Tool: Subnet Calculator

The subnet calculator helps you design networks by taking an IP address and network mask and returning information such as network, broadcast address, and host range.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now