Opportunity to opportunity product is ok but why do you want to populate data from opportunity product to opportunity? Can you explain the business logic or scenario? so that we can let you know the possible solution, if any.
For one project I created the concept of a "Primary" Opportunity Product Line record for each Opportunity. Stored the Primary OLI Id in a lookup field on the Opportunity, and used formulas fields to pull the other fields from the OLI onto the Product. I Created trigger code to maintain the Primary given the various things that could change to the OLI's. The client had some other needs as well with regard to the primary including automatically selecting a Product as Primary if it was the only OLI for the Opportunity
The main business need for this was to for reporting on the Opportunity and Account.
So, perhaps you could approach it that way?
(But, as was said earlier, Opp to OLI is a 1:n relationship and so this approach only gives you data on one Product.)
As relation between Opportunity and Opportunity is 1:M, System will be confuse to pick data from which opportunity product line item.
Opportunity to opportunity product is ok but why do you want to populate data from opportunity product to opportunity? Can you explain the business logic or scenario? so that we can let you know the possible solution, if any.
For one project I created the concept of a "Primary" Opportunity Product Line record for each Opportunity. Stored the Primary OLI Id in a lookup field on the Opportunity, and used formulas fields to pull the other fields from the OLI onto the Product. I Created trigger code to maintain the Primary given the various things that could change to the OLI's. The client had some other needs as well with regard to the primary including automatically selecting a Product as Primary if it was the only OLI for the Opportunity
The main business need for this was to for reporting on the Opportunity and Account.
So, perhaps you could approach it that way?
(But, as was said earlier, Opp to OLI is a 1:n relationship and so this approach only gives you data on one Product.)
Best, Steve.