I have 2 object : one and two. Onject two had a field named prop__c and I want to put the value of this field in the Owner field of the object one, is it possible ?

The prop__c field is a formula field and the formula is : Conc__c.Owner.Id

Thank you


Edited Answer:

Owner field is a lookup to User object.
You can only put a User Id or Queue Id (for Leads and Cases) in that field.
if Prop__c contains a User Id than you can do that.

  • Ok, my field Prop__c is a formula field that contains this formula : Conc__c.Owner.Id is that possible too ?
    – dou
    May 17 '16 at 14:08
  • Yes, you can do it. You can achieve this using trigger (might be process also) depending on the object schema.
    – C0DEPirate
    May 17 '16 at 14:12
  • When I put someting like : acc.Owner = a.Prop__c; with acc an account and a an sObject, it says 'Illegal assignment from string to user', maybe it is not possible even with the formula ?
    – dou
    May 17 '16 at 14:18
  • Are you doing that in trigger?
    – C0DEPirate
    May 17 '16 at 14:19
  • In an hadler that I call in a trigger, how do you think I should put that statement ?
    – dou
    May 17 '16 at 14:20

Unless Prop__c is a lookup to user then this would not be possible.

If it is then a trigger can be used to copy this over or a workflow

This link explains why Salesforce record ownership is set up the way it is.

  • Prop__c is a formula field which stores UserId. This is possible using trigger or process.
    – C0DEPirate
    May 17 '16 at 14:15

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.