Hi,
I'm just a newbie in dataset/progress. I have a couple of questions. I have defined a dataset with some temp-tables, they all related to the same foreign key. Look below for an example:
[ procedure exposeWSDS]
ttOrder
field ordernumber as int XML-NODE-TYPE "hidden"
field order.... and so on...
ttOrderLine
field ordernumber as int XML-NODE-TYPE "hidden"
field linenumber as int... and so on.....
DEFINE DATASET dsOrd FOR ttorder, ttorderLine
DATA-RELATION dsOrderRel FOR ttOrder, ttOrderLine
RELATION-FIELDS (ordernumber, ordernumber) NESTED.
DEFINE INPUT PARAMETER DATASET FOR dsord.
[end procedure exposeWSDS]
This procedure is exposed as a webservice with the tool proxygen. Like you can see the foreign keys are hidden elements. This means that the sender doesn't sends the foreignkeys..But I need the foreign keys to relate the temp-tables, so how i can realize this? Is there possibility when you create a temp-table that a trigger will activate and fillin the ordernumber (random) automatically. No I get for each ordernumber the value 0. Perhaps there is another design that you can implement. I appreciate your help!
Regards,
Buras
When on 10.2A, I'd rather use the FOREIGN-KEY-HIDDEN attribute of the data-relation (together with NESTED).
This hides the foreign keys when writing out to XML and populates the foreign keys values with the parent records values when reading from XML.
I have a related question. I have created my webservice operations, one of which allows the client to post back changes made to a dataset. In the temp table definations, I created a BI table for each of the tables. The problem is I am not sure how the client handles the manipulation of the BI table data. Is there any sample code that shows how it it handled on a generic client? We are going to be using ASP .Net, but I want to know how a client that is using just XML to handle the data, would go about it.
Thank you
Hello Mike,
I'm using 10.2A. The disadvantage of FOREIGN-KEY-HIDDEN is that is only one level deep. That means that the outer parent is still using a key, but the children are not. And if you have grandchildren than the parent must have a key also. Another thing is that when you use proxygenerator, FOREIGN-KEY-HIDDEN are ignored.
My purpose is to make a customized XML that can be used to exchange information. I want to consume this similair xml:
...
...
.....
Temp-tables are: ttorder, ttcustomer, ttarticle, ttunitinformation (all share one foreign key (ordernumber), but I don't want the foreign key be public).
DEFINE DATASET dsOrd FOR ttorder, ttcustomer, ttarticle,ttunitinformation
DATA-RELATION ttOrderRel FOR ttOrder, ttcustomer
RELATION-FIELDS (ordernumber, ordernumber)
DATA-RELATION ttOrderRel2 FOR ttorder, ttarticle
RELATION-FIELDS (ordernumber, ordernumber)
DATA-RELATION ttOrderRel2 FOR ttarticle, ttunitinformation
RELATION-FIELDS (ordernumber, ordernumber)
You can use SOAPUI client (free tool on the net) to test webservice. If have you used Proxygen, then a wsdl will be generated. You can simply test the WSDL with SOAPUI and simulate the client.
I have a tool to test the webservice. I am asking a question about how the client and the service should handle the before image table when a change is made.