cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
DTS_Dev01
New Member

keep the duplicated values from the past time

Hi,

 

I have a column as "amount" requested from my customer to save all the amounts he predicted to make in 2021/9.

But no matter what amount he filled in, this prediction will be ended up in 2021/8/15.

And he can make a comparison with the truth of 2021/9.

So I need to keep the prediction in another column like "Prediction_2021/9" that we can make the checking procedure.

 

In Dataverse, I made a calculated column that 

"Prediction_2021/9" would be set as the copy of "amount"

if the modified date before 2021/8/15,

but the problem is

if "amount" was modified AFTER 2021/8/15, whatever the amount saved in "Prediction_2021/9" would be CLEARED.

I did nothing in Else part that I have no idea how to prevent the "refreshing".

What should I do to keep the previous amount there without clearing?

 

Thanks.

1 ACCEPTED SOLUTION

Accepted Solutions
dpoggemann
Resident Rockstar
Resident Rockstar

Hi @DTS_Dev01 ,

 

You are right, if you do not put an else condition in here it will clear the field and you can not reference the current value of the field or you will get a circular reference.

 

I was able to accomplish your business requirement in a test utilizing. a business rule instead and not using a calculated field.  I created a field called Prediction BR 2021/9 and setup a business rule to set the value to the Amount column if the Date Check field was < 2021/8/15.  This set the value appropriately up until I utilized a date after this date and then it did not set it at all and kept the previous value in the column.

 

Screen Shot 2021-07-28 at 5.19.58 AM.png

 

Hopefully this helps.  Please accept if answers your question or Like if helps in any way.


Thanks!


Drew

View solution in original post

3 REPLIES 3
dpoggemann
Resident Rockstar
Resident Rockstar

Hi @DTS_Dev01 ,

 

You are right, if you do not put an else condition in here it will clear the field and you can not reference the current value of the field or you will get a circular reference.

 

I was able to accomplish your business requirement in a test utilizing. a business rule instead and not using a calculated field.  I created a field called Prediction BR 2021/9 and setup a business rule to set the value to the Amount column if the Date Check field was < 2021/8/15.  This set the value appropriately up until I utilized a date after this date and then it did not set it at all and kept the previous value in the column.

 

Screen Shot 2021-07-28 at 5.19.58 AM.png

 

Hopefully this helps.  Please accept if answers your question or Like if helps in any way.


Thanks!


Drew

View solution in original post

Hi Drew,

 

Thank you for the solution!

Sorry because there are still some problems that I have to fit my original design,

But I am really appreciated for your help!

 

Dave

dpoggemann
Resident Rockstar
Resident Rockstar

Hi @DTS_Dev01 , you could use combination of both approaches and on the else set the value to the one set in the business rule.  The other field would need to be on the form but you could hide it…

 

thanks,

 

Drew

Helpful resources

Announcements
PA_User Group Leader_768x460.jpg

Manage your user group events

Check out the News & Announcements to learn more.

Power Query PA Forum 768x460.png

Check it out!

Did you know that you can visit the Power Query Forum in Power BI and now Power Apps

Carousel 2021 Release Wave 2 Plan 768x460.jpg

2021 Release Wave 2 Plan

Power Platform release plan for the 2021 release wave 2 describes all new features releasing from October 2021 through March 2022.

PowerPlatform 768x460.png

Microsoft Learn

Check out our new Discover Your Career Path blog post series and get all the details.

Users online (1,885)