5 Replies Latest reply: Jan 4, 2010 4:40 PM by David Vasseur RSS

    Not sure if I can use the AGGR function for this problem

    dcroft

      Hi,

      I have a table with order details for individuals

      The main fields for this problem are

      Person Id

      Order Date

      I need to be able to count distinct Person Id where that Person has placed more than one Order in the last 12 months, for example using the data below, the answer would be 2

      Person Order Date

      123 03-jan-2009

      123 06-jan-2009

      345 07-jan-2009

      345 08-jan-2009

      456 02-jan-2009

      567 11-feb-2009

      567 19-jun-2009

      I was wondering if I could use the AGGR function to do this? I never used it before - any advice would be most welcome.