3 dimension grouping report

gulamdastagirgulamdastagir Member Posts: 411
hi navies,

how can we achieve the following report grouping

Global Dimension 2
>>Global Dimension 1
>>>Dimension#3(salesperson Code)
>>>>Customer No.

The Table is Customer.Any new keys should be created?
Regards,

GD

Comments

  • DaveTDaveT Member Posts: 1,039
    Apart from the obvious answer of adding in a new field for dim 3 and validating in the value there is another way.

    Group your report on dim 1 -> dim 2. instead of printing on the customer have a indented dataitem running off a temporary default dimensions record. in the predata item fill the tempory table with records for dim 3 from a temporary customer record. only process the dataitem on change of dim 1 or dim 2 i.e.

    if ( dim 1 = olddim1 ) or ( dim 2 = olddim2 ) then
    break;

    tempdefdim.deleteall;
    tempcust.setfilter( dim1, customer.dim1 )
    tempcust.setfilter( dim2, customer.dim2 )
    if tempcust.findset then
    repeat
    insert into tempdefdim
    until tempcustust.next = 0;

    a lot of work but worth a try if you don't want to modify the customer table.

    (I know it's not proper syntax but I'm not at my Nav machine - and too lazy to type :D )
    Dave Treanor

    Dynamics Nav Add-ons
    http://www.simplydynamics.ie/Addons.html
Sign In or Register to comment.