How to display a sum of a group in a report

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Babu Ghosh
    New Member
    • Oct 2010
    • 4

    #1

    How to display a sum of a group in a report

    In a Report in access I have created a text box which is the 'Product Value' of two other Text Boxes in the same Report. Now, I have created a Group where in the Group Footer another Text Box shall show the totals of all the 'Product Value' Text Boxes under the same Group. While creating this I am getting #error message. Please be noted that the 'Product Value text' box does not have any existing fields with the form or table. Please advice me what to do.
  • nico5038
    Recognized Expert Specialist
    • Nov 2006
    • 3080

    #2
    You can only use recordset fields in the footer to sum.
    Sometimes you'll need to "move" the calculation to the report's query and sum that calculated field in the footer.

    Nic;o)

    Comment

    • Babu Ghosh
      New Member
      • Oct 2010
      • 4

      #3
      How to display a sum of a group in a report

      Thanks Nico,
      But can you please give me any details of the procedure of moving the text box to a query.
      amitabha

      Comment

      • nico5038
        Recognized Expert Specialist
        • Nov 2006
        • 3080

        #4
        Just place the calculation in the query as a computated field.

        Would be like:
        Code:
        select a, b, a + b as Calc from tblX
        The a + b will now appear as a new column "calc" in the query.

        Nic;o)

        Comment

        • Babu Ghosh
          New Member
          • Oct 2010
          • 4

          #5
          thanks for this nico but i cant get it where to select in query? and what to write. actually i have created a text box named 'SHARE CONSIDERATION' in a report named as 'LAND COST' where the 'SHARE CONSIDERATION' text box calculates a product of two text boxes in the same report i.e text box 'SHARE CONSIDERATION' = 'SAHRE RATE'* 'SHARE LAND AREA/KATAH'. It is working. But I am facing a problem when I am inserting another text box named as 'text 41' where a sum of all the value of 'SHARE CONSIDERATION' shall show in the report footer. When I am creating this 'text41' where I am inputting in expression builder =Sum([SHARE CONSIDERATION]) it is showing error message. Can you please get me out. Actually I have a least knowledge in access.
          amitabha

          Comment

          • nico5038
            Recognized Expert Specialist
            • Nov 2006
            • 3080

            #6
            Just insert the "share rate * share land" formula in the select query of the report's query as indicated in my previous comment. Then remove the unbound textfield and place the field from the fieldlist.

            Nic;o)

            Comment

            • dsatino
              Contributor
              • May 2010
              • 393

              #7
              =sum([product value])

              This doesn't work?

              Comment

              • Babu Ghosh
                New Member
                • Oct 2010
                • 4

                #8
                hi, nico, i am trying to work out as per your suggestion but it is not working out

                Comment

                • nico5038
                  Recognized Expert Specialist
                  • Nov 2006
                  • 3080

                  #9
                  Can you post the query text here ?

                  Nic;o)

                  Comment

                  Working...