function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
Hari G SHari G S 

Formula Field

Hi,

I have created a custum formula field in Quote Line Item Object and the formula was Product2.Description. When i do check syntax it shows no error. But when i try to create a custom formula field in a custom object it shows an error Field Product2 does not exist. Check spelling. Why this is happenening? Please help.

Thanks and Regards,
Hari G S

Best Answer chosen by Admin (Salesforce Developers) 
kiranmutturukiranmutturu

your formula filed should be like this i thought.. Product__r.Description.. try this..

All Answers

kiranmutturukiranmutturu

you are trying to create cross object formula field .. do the custom object has the relation with procuct2 or not? 

Hari G SHari G S

 

Hi Kiran,

 

Thanks for the reply. Could you please tell me how to relate my custom object to the Product object. I havent set any relation while creating my custom object.

 

Thanks& Regards

Hari G S

hchhch

Create a lookup or master-detail relationship from the custom object to the Product object. Then you can create cross object formula field.

Hari G SHari G S

 

Hi,

 

In the Account object i have created a new custom lookup field and is related to Product object. When i again try to create a formula field with the formula Product2.Description it shows an error.

 

Thanks & Regards

Hari G S

kiranmutturukiranmutturu

your formula filed should be like this i thought.. Product__r.Description.. try this..

This was selected as the best answer
Hari G SHari G S

Thanks Kiran, its working. :)