Calculating Invoice Qty And Amount Group by Month Year

vnprocvnproc Member Posts: 41
Hi Everybody,

I'm having problems with group quantity and Amount by the month of Posting Date (Month-Year)
I wrote a Qty and Sales Amount calculation from the Value Entry table. But it is impossible to show the Posting Date Group by Month-Year.
 WITH ValueEntry DO BEGIN
      SETRANGE("Item No.", Item."No.");
      SETRANGE("Item Ledger Entry Type","Item Ledger Entry Type"::Sale);
      SETRANGE("Posting Date",FromDate, Todate);
      CALCSUMS("Invoiced Quantity","Sales Amount (Actual)");
      SalesQty += -"Invoiced Quantity";
      SalesAmt += "Sales Amount (Actual)";
END;

I need the data to be listed under the Month-Year group. Please help me with 1 solution.
Thanks very much.

Month-Year Item No SalesQty SalesAmt
09-2020 A100 1000 5000
09-2020 A200 500 2500
09-2020 A300 400 5000
10-2020 A100 1500 8000
10-2020 A200 550 3000
10-2020 A400 200 4000


Comments

  • ishyampandeyishyampandey Member Posts: 22
    Take Date Data item and group on month. Date data item automatically solve your issue. Filter your from date and to date on Period start field of date data item.
Sign In or Register to comment.