While cloning the Opportunity, is it possible to copy only certain field values. I want some fields to be empty whichmeans it should not contain the existing opportunity value.



3 Answers 3


The simplest solution is to use a button as described in the accepted answer to this post: Provide standard clone button functionality to a button on vf page where the page opens in edit mode and when saved, becomes a cloned record. One can clear the fields that aren't needed before saving the cloned record. BTW, the latter can now be done using an action method as well instead of a button (see the newest answer to that question for details).


This can be done simply by first querying the record you wish to clone, and only querying for the fields you wish to be filled. Any field which is not included in the query will not be filled out on the clone, with the obvious exception of fields like CreatedDate which are set by the system.


Try something like my previous solution here. This can be customized to pull in whatever you need only in your clone - in a couple lines of code and still set up for cloning using the $Action command

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .