Alfasith AX

Alfasith AX
اللَّهُمَّ انْفَعْنِي بِمَا عَلَّمْتَنِي، وَعَلِّمْنِي مَا يَنْفَعُنِي، وَزِدْنِي عِلْمًا

Tuesday, September 26, 2017

An update conflict occurred due to another user process deleting the record or changing one or more fields in the record

Hi,


Record conflict errors.

You needs to block the records to your session these are the ways you can lock the table records.

1. ttsbegain and ttscommit will also plays this role.

2. OCCEnabled true the property in table level.

3. In X++

a. select statement.

 select pessimisticLock purchTable where purchTable.PurchId == "XXXXX";

b. recordset statement.

update_recordSet pessimisticLock purchLine setting
            RemainInventPhysical = 0,
            RemainPurchPhysical   = 0,
            PurchStatus           = PurchStatus::Canceled
            where purchLine.PurchId == purchTable.PurchId;


Thanks,
Alfasith

No comments:

Post a Comment

SQL code to upate one Legal entity banner to all the legal entity in D365

 Hi, update companyimage set  companyimage.Image  = companyimageA.Image  from  ( select Image from companyimage where dataAreaid = 'USF...