1
votes

I have a report with an edit link. The Edit link is Id. This report retrieves records from different databases.

My requirement is to insert those records into my database when the edit link is clicked. Please find the image below.

I need to insert these two records into my database table on clicking on the edit link.

How do I perform this in APEX?

enter image description here

2

2 Answers

1
votes

Well, I would rather have another dedicated column on this report that does the required action than use an Edit link which is primarily used to drill down to a record in detail.

You can follow this article to achieve the desired action by creating a button on a report which performs DML action. Just make sure to accommodate the necessary changes to meet your needs.