Describe the bug
The rule does not seem to be working correctly.
To Reproduce
We haven't been able to reproduce it outside our app (a test app using the same VSCode extension and BC server, with identical code as the one below does not raise the warning). There is a something else that I must be missing, but I'm posting it here to see if we can find what.
This is, after a few simplifications, the code I've left in one table field (the original CalcFormula was much more complex):
field(7142200; "IDPWHS Qty. Buffer"; Decimal)
{
CalcFormula = Sum("IDPWHS Read Buffer".Quantity where("Doc No." = field("Document No.")));
Caption = 'Qty. Read';
Editable = false;
FieldClass = FlowField;
DecimalPlaces = 0 : 5;
}
It raises this warning: The FlowField Quantity of "IDPWHS Read Buffer" should be added to the SIFT key.
This is the key I've created for that CalcFormula, in the "IDPWHS Read Buffer" table:
key(Key7; "Doc No.")
{
SumIndexFields = Quantity;
}
Just for reference, this are the "Doc No." and "Quantity" fields:
field(2; "Doc No."; Code[20])
{
Caption = 'Document No.';
DataClassification = CustomerContent;
}
field(6; Quantity; Decimal)
{
Caption = 'Quantity';
DataClassification = CustomerContent;
DecimalPlaces = 0 : 5;
}
Expected behavior
There is a SIFT index for the required key and the Quantity field, so no warnings should be raised.
5. Versions:
I can verify that I have the same issue with the rule.
Confirmed, the warning still fires when it has been fixed very specifically: see warning here:

but see the key I added just for that purpose here:

It seems this is also another warning that fires for keys that exist in the base application but to which we cannot add SumIndexFields, which it should not do until we can add them... no point telling us 'you should do X' when you don't let us ;-)
Same here. Take a look at this example. I get a warning on field 84 but not 85 even though they are delcared in the same way and use the same underlying table and key.


I have a bit different problem.
The rule does not respect field type, so if we use max on a date field (to find the last date) the warning is useless (SIFT index is for the numeric fields only)...

Confirmed.. this doesn't make sense either..

Same here, I have added an extension field for Vendor Table and Get sum to form my customize table, I have set SumIndexFields but still appear this misleading information



Most helpful comment
It seems this is also another warning that fires for keys that exist in the base application but to which we cannot add SumIndexFields, which it should not do until we can add them... no point telling us 'you should do X' when you don't let us ;-)