Jump to content

Sale Order API updating wrong line detail


 Share

Recommended Posts

Hi,

We are on X3 V12 90.24.54. 

I am updating some sales orders via C# using web services. What I have noticed is that the sales line details API is updating incorrect line details, even after explicitly setting  product code + line numbers. It seem that it is updating line detail based on the order received rather than observing the product code and line number.

An example is I have a sales order with four line details (1000 -> 4000). I only want to update line 4000.

My XML payload to the webservice is:

<?xml version="1.0" encoding="UTF-16"?>
-<PARAM xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
	-<GRP ID="SOH0_1">
		<FLD NAME="BPCORD">ABC001</FLD>
		<FLD NAME="SALFCY">UATSITE</FLD>
	</GRP>

	-<TAB ID="SOH4_1" SIZE="1">
		-<LIN NUM="1">
		<FLD NAME="ITMREF">HNP00019</FLD>
		<FLD NAME="NUMLIG">4000</FLD>
		<FLD NAME="SOPLIN">4000</FLD>
		<FLD NAME="QTY">12</FLD>
		<FLD NAME="ITMDES">This is a closed line really</FLD>
		</LIN>
	</TAB>
</PARAM>

 

I'm calling the webservice "SOH" endpoint, using the Modify method. The call is working correctly and updating the line detail, unfortunately, its the wrong line detail.

image.png.5d9dfc2b21b0197f102d8c6e073e776e.png 

 

I've tried omitting the SOPLIN field, etc. If I omit the NUMLIG field, then a new line detail is inserted (as expected).

Any ideas?

Link to comment
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
 Share

×
×
  • Create New...