46
If you have a database with let us say 1.5 Milion items in it and create a table extension on the Item table with a field "My Item Group" then, we have in a custom table a FlowField named "Number of Items" which count the number of items per "My Item Group" in a sample code similar to this:
tableextension 50000 MyItemExt extends Item

{

fields

{

field(50000; "My Item Group"; Code[20]) { TableRelation = "My Item Group".Code; }

}

}



table 50000 "My Item Group"

{

fields

{

field(1; Code; Code[20]) { }
field(2; Description; Text[100]) { }

field(3; "Number of Items"; Integer)

{

FieldClass = FlowField;

CalcFormula = Count(Item where("My Item Group" = field(Code));

}

}

}

Whenever you try to display the "My Item Group" the request will take up to 90 seconds to capture the data. The reason seems to be the Unnecessary table joining. If you perform the same call on the SQL without the table joining the call takes less than a second to complete. I believe that for FlowField (Count, Exists, and in some cases for other types) that joining is not necesary.
Category: Development
STATUS DETAILS
Needs Votes
Ideas Administrator

Thank you for this suggestion! Currently this is not on our roadmap. We are tracking this idea and if it gathers more votes and comments we will consider it in the future. Best regards, Business Central Team