I am trying to figure out how to get the last edited feature to be the one filtered out.
This works for part of the day. There are just a few hours where it does not work. From 10am (local time) until I enter that days data. I usually enter new data midday. It does not pull in the last edited based on time. It pulls in based on date and when there are two from the same day it will pull the wrong feature.
I get No Value because it is pulling the wrong edit date.

My expression:
var portal = Portal("https:///portal/");
var fs = FeatureSetByPortalItem(
portal,
"",
1,
[
"Date_",
"W_F_MGD",
"E_F_MGD",
"TOTAL_W_E_MGD",
"TID_FLOW_MGD",
"REEDER_Percent_FULL",
"TAP_FLOW_MGD",
"PLANT_PRODUCTION_MGD",
"last_edited_date"
],
false
);
// Find the most recent date from the date field to filter the FeatureSet for the latest record
var maxDate = Text(Date(ToLocal(Max(fs, 'last_edited_date'))),"YYYY-MM-DD");
return Filter(fs, "Date_ = @maxDate");