Hello -
Having trouble figuring out how to filter for the following. Trying to find records in the array that have matching store numbers and of that set filter out those with "Promotion End Date" = '9999-12-31T00:00:00'. There can be numerous sets of records with the same store number in the parsed JSON input.
Here is sample of the data. In this sample there are 5 records. After the filter(s) run there should only be 4 records with the third store number 55 record filtered out.
{
"Store Number": 45,
"Store Name": "abc",
"Price": 4.44,
"Price Type": "STORE",
"Price Start Date": "2025-01-01T00:00:00",
"Promotion Type": null,
"Promotional Price": 4.44,
"Promotion Start Date": "2025-01-01T00:00:00",
"Promotion End Date": "9999-12-31T00:00:00",
"Coupon Number": null,
"Price Status": "FUT"
},
{
"Store Number": 55,
"Store Name": "xyz",
"Price": 1.11,
"Price Type": "STORE",
"Price Start Date": "2025-02-03T00:00:00",
"Promotion Type": "M",
"Promotional Price": 1.11,
"Promotion Start Date": "2025-02-03T00:00:00",
"Promotion End Date": "2025-02-28T00:00:00",
"Coupon Number": null,
"Price Status": "FUT"
},
{
"Store Number": 55,
"Store Name": "xyz",
"Price": 2.22,
"Price Type": "STORE",
"Price Start Date": "2025-01-06T00:00:00",
"Promotion Type": null,
"Promotional Price": 2.22,
"Promotion Start Date": "2025-01-06T00:00:00",
"Promotion End Date": "2025-02-02T00:00:00",
"Coupon Number": null,
"Price Status": "FUT"
},
{
"Store Number": 55,
"Store Name": "xyz",
"Price": 2.22,
"Price Type": "STORE",
"Price Start Date": "2025-03-01T00:00:00",
"Promotion Type": null,
"Promotional Price": 2.22,
"Promotion Start Date": "2025-03-01T00:00:00",
"Promotion End Date": "9999-12-31T00:00:00",
"Coupon Number": null,
"Price Status": "FUT"
},
{
"Store Number": 129,
"Store Name": "def",
"Price": 0,
"Price Type": "STORE",
"Price Start Date": "2025-01-01T00:00:00",
"Promotion Type": null,
"Promotional Price": 0,
"Promotion Start Date": "2025-01-01T00:00:00",
"Promotion End Date": "9999-12-31T00:00:00",
"Coupon Number": null,
"Price Status": "FUT"
}
Appreciate any assistance.
Thanks!