How to group by a field for each page of report

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • mcupito
    Contributor
    • Aug 2013
    • 294

    How to group by a field for each page of report

    I am trying to run a report that separates each page of the report by EmployeeID.

    Here is the SQL, am I missing something?

    Code:
    SELECT Sum([PayoutTbl]![PytUnits]*[NAV_Tbl]![NetAssetValue]) AS PytGross, CheckTbl.CheckDate, Sum(PayoutTbl.PytUnits) AS SumOfPytUnits, 
    CheckTbl.TaxFederal, CheckTbl.TaxState, [CheckTbl]![TaxFicaR]+[CheckTbl]![TaxFicaM] AS [Fica Tax], CheckTbl.TaxLocal, AssociateTbl.EmployeeID, 
    AssociateTbl.AstFirstName, AssociateTbl.AstLastName, AssociateTbl.HomeStreet, AssociateTbl.HomeCity, AssociateTbl.HomeState, AssociateTbl.HomeZip
    FROM AssociateTbl INNER JOIN ((NAV_Tbl INNER JOIN (CheckTbl INNER JOIN PayoutTbl ON CheckTbl.CheckNo = PayoutTbl.CheckNo) ON NAV_Tbl.NAV_Date = PayoutTbl.PytNAV) 
    INNER JOIN AwardTbl ON PayoutTbl.AwardID = AwardTbl.AwardID) ON AssociateTbl.EmployeeID = AwardTbl.EmployeeID
    GROUP BY CheckTbl.CheckDate, CheckTbl.TaxFederal, CheckTbl.TaxState, [CheckTbl]![TaxFicaR]+[CheckTbl]![TaxFicaM],
     CheckTbl.TaxLocal, AssociateTbl.EmployeeID, AssociateTbl.AstFirstName, AssociateTbl.AstLastName, 
    AssociateTbl.HomeStreet, AssociateTbl.HomeCity, AssociateTbl.HomeState, AssociateTbl.HomeZip;
    This gets me the desires results, but on the report it groups them together, even though I am grouping by AssociateTbl.Em ployeeID in the query.

    Any ideas? Thanks!
  • jimatqsi
    Moderator Top Contributor
    • Oct 2006
    • 1288

    #2
    Are you saying that you want to make each employee start at the top of a new page? If so, add a page break object to the employeeID footer area. Page Break is available in the toolbox.

    Jim

    Comment

    • mcupito
      Contributor
      • Aug 2013
      • 294

      #3
      Thanks for the reply. I'm not getting an "EmployeeID Footer" when I try to group & sort. I am only getting a header.

      Comment

      Working...