Event you made is triggers when a new Purchase order is created. Since the event runs within the same transaction as creating the record, the select does not ‘see’ the record since the transaction is still not committed.
To avoid that, you can run your code as a background job, which would run after the roder is created.
Check this post for more details on running a code block as a background job
Event you made is triggers when a new Purchase order is created. Since the event runs within the same transaction as creating the record, the select does not ‘see’ the record since the transaction is still not committed.
To avoid that, you can run your code as a background job, which would run after the roder is created.
Check this post for more details on running a code block as a background job
Please proceed with Damith’s suggestion if you want to Release Purchase Order with PO header creation only else you can configure your event at Purchase Order Line instead.
System getting null values for Objid and Objversion with your select statement.
We use 3 different kinds of cookies. You can choose which cookies you want to accept. We need basic cookies to make this site work, therefore these are the minimum you can select. Learn more about our cookies.