developpement arround sage x3 using web service

I want to save data from sage to my sql database, the problem is in soap i get a group structure. example:

"ITM0_1": {
"TCLCOD": "ASSET",
"ZTCLCOD": "Invest",
"ITMSTA": "1",
"ITMSTA_LBL": "Actif",
"ITMREF": "ASS001",
"DES1AXX": "Serveur informatique"
},
"ITM1_1": {
"DES2AXX": "Serveur",
"DES3AXX": ""
},

etc...

but i don't think that's right to create lot of group tables and even there is no relations between those groups to create classes for them for 1 model like ITMMASTER. any idea how i can deal with this structure.

Parents
  • wassimmeziou, 

    A little more detail of the table structure and object structures you're working with here might be helpful, as I'm not sure exactly what I'm looking at. Are you calling an object web service? If so, what are you passing into that web service (you can provide JSON or XML)?

    At first glance, it looks like you might be trying to pass multiple values into the web service at the same time. If that's the case, I'd suggest restructuring into a subprogram web service and writing to your table in there. Obviously, there are some gotchas on that with circumventing the native code; if that's a concern, you could loop through your inputs in the subprogram and call the object web service for each entry.

Reply
  • wassimmeziou, 

    A little more detail of the table structure and object structures you're working with here might be helpful, as I'm not sure exactly what I'm looking at. Are you calling an object web service? If so, what are you passing into that web service (you can provide JSON or XML)?

    At first glance, it looks like you might be trying to pass multiple values into the web service at the same time. If that's the case, I'd suggest restructuring into a subprogram web service and writing to your table in there. Obviously, there are some gotchas on that with circumventing the native code; if that's a concern, you could loop through your inputs in the subprogram and call the object web service for each entry.

Children