Hi,
I’m trying to use “SQL Select Statement” in “Grid lookup” of “Group By” function, with 2 level group by option in my grid.
Query = Select Group, Sub_Group, Item, Sum(Value) from MyTable Group By Group, Sub_Group, Item
I added a Group By option in my Application Grid for Group and Sub_Group, and used SQL Select Stamenent to replace the Group code value with the Group description, and Sub_Group code value with the Sub_Group description.
All seem to works fine if each groups have more than 1 Sub_groups returned
Gr Subgr
01 01 Name A (Ok)
01 02 Name B (Ok)
02 01 Name C (Ok)
02 02 Name D (Ok)
But if the Sub_Goup have the same code of the previous one ( even if the group change ), the SQL statement seem not to be updated:
Gr Subgr
01 01 Name A (Ok)
02 01 Name A (Wrong)
03 01 Name A (Wrong)