Respective record is not getting selected for settlement ?Anything missing ?

Due to some record missing so i updated missing records in VendSettlement and VendTrans for which i am able to see all negative quantities in close transaction editing form for a paricular vendor.But when i mark for example 90 so it should select the other record -90 which is already in that form.Why is it not selecting ?So i am not able to do settlement.

Why these records are missing? Have you investigated it? So that you can avoid it in future.

Have you updated the TransRecId and offsetRecId fields properly in vendSettlement table?

TransRecId is the vendTrans RecId(also make sure TransCompany field is updated to that DataAreaId of vendTrans, see relations in vendSettlement)

offsetRecId is the mapping between the settled transactions ,

example the invoice and payment,

If the TransRecId of invoice is “123”, TransRecId of payment is “456” in vendSettlement

then OffsetRecId of the payment will be “123” , offsetRecId of the invoice will be “456”

Hi Kranthi,

Checked the same in VendSettlement and updated like

payment transrecid ->invoice offsetrecid

invoice transrecid->payment offsetrecid

But still when i mark payment,the invoice is not getting selected.

How about TransCompany? (which is same as vendTrans.DataAreaId).

Updating the records manually is not suggested which can ignore the required business logic execution and further data inconsistency.

Hi kranthi

I completely agree with you. The thing is that i am using Dot net integration with Ax where dot net tables and ax tables are mapped accordingly.So due to some connection issue PO got invoiced but recovery amounts not updated in close transaction editing form.So from dot net tables i got records and inserted/updated in respective tables for which i am able to see all those missed records.But what missing thing is when i mark any record the respective opposite sign value doesn’t get selected as standard does.

But kranthi two things i would like to tell …

First is Table always shows that company which ax is opened.So we always find the same company in Transcompany and dataAreaId.Anyway i checked both are same.If i am wrong please clarify it.

And Second is when i debug the code CustVendSettlement::markOffsets there for standard it loops twice but in my case while loop is running one time.

Even i can’t understand what CustVendSettlement offset = this.data() and while loop are doing here.

As you are trying to manually update the records, there is a chance of ignoring it(Transcompany ) and this will not be updated automatically as this not a system field like dataAreaId.

It means the fields used in the where clause are not properly update.

CanBeReserved - set it to Yes

offsetCompany - same as TransCompamy.

Finally, you can have a similar transaction in test (posted in AX) and compare with the data that you have entered manually to understand the discrepancy…