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
Krishna_225Krishna_225 

Parent field to get update with the Child field which is entered earliest than other field

Hello Develpers,
I have a requirement where the Account's field should be updated by Order__C which is a child object.
I have a formula field on Order__C which is 
IF( (Account.First_Purchase_Date__c = Order_Date__c) && Account.First_Purchase_Year__c = '2018' , Order_CC__c , 0)
There is a field on Account Object which is updated by Order_CC__c by trigger
The problem here is, if we enter another order with same date and year as previous order, the new value is updating. I only need the first value to be populated in the Account's field from Order.
Please help me solving out this puzzle.

Thank you in advance
Krish