Re: How to overcome 'Duplicate Index error' in Magic xpa #-1

Florian Groothuis

If you swich to create  mode and determine your OrderID the record is not written yet. So when the record ís written it is possible that another user created a new order too but was earlier with saving his record.

Set the OrderID to it’s maximum + 1, so if it is 4 digits set it to 10.000. In the RecordSuffix you can determine the real OrderID bij LastOrderID+1 and write the record


On create mode start a subtask to create the orderheader and then let the user specify the orderheader in ModifyMode





Van: [] Namens abinaya.arokiadoss@...
Verzonden: vrijdag 9 juni 2017 11:39
Onderwerp: [magicu-l] How to overcome 'Duplicate Index error' in Magic xpa #-1


I am using logic 'Last OrderID +1 = New OrderID' to write data in DB, while placing a new order. It gives me 'Duplicate Index error'. How to achieve this?

Met vriendelijke groet - With kind regards,

Florian Groothuis
+31 (0)6 21927914

Meilink Beheer Borculo B.V. • Kamerlingh Onnesstraat 1
7271 AZ  Borculo • Nederland • +31 (0)545 253525
KvK 08009803 • Our general terms and conditions apply • Disclaimer

Join to automatically receive all group messages.