How do I get the sum of a field in a sub-form

How do I get the sum of a field in a sub-form

I am completely new to Zoho Creator.  Using the SUM documentation below, I attempted to use a formula field to sum a single numeric field in a sub-form.  I could never get it to work.  I then tried with all fields in a db with only one form.  Still no go, and I got the same errors.

Should sum() work in the Expression property of a Formula field?  If not, where do I use it to get a total for a field?  If the sum function is not the way to go, what is?

Here are results of various entries in Expression property
    Form - TestForm
    Numeric Field - NumberIn
    Formula Field - SumNumberIn

1 Numberin   Works, but of course it only shows each record's value, not a total
2 sum(NumberIn)   "Not able to find 'sum' function"
3 Testform.sum(NumberIn)  and SumNumberIn = Testform.sum(NumberIn)    "Expression not supported in formula"



Sum Function

//to sum the total value of a numeric field in the form 
<variable> = <Form_Name>.sum(<Numeric Field Name>);

//to sum specific records with a given criteria
<variable> = <Form_Name>[criteria expression].sum(<Numeric Field Name>);



where,
<variable> refers to a user defined variable name or a form field.

Example:

//to find total sales value 
Total_Sales = FormA.sum(Amount);

//to find the total sales value for Item="Printer"
ItemA = FormA[Item == "Printer"].sum(Amount);



    Access your files securely from anywhere

        Zoho Developer Community




                                  Zoho Desk Resources

                                  • Desk Community Learning Series


                                  • Digest


                                  • Functions


                                  • Meetups


                                  • Kbase


                                  • Resources


                                  • Glossary


                                  • Desk Marketplace


                                  • MVP Corner


                                  • Word of the Day



                                      Zoho Marketing Automation
                                              • Sticky Posts

                                              • Share your success story

                                                We would like to hear from our passionate users how much Zoho Creator has changed the way you work and benefited you. If you would like to share your story to us and be featured as a proud user of Zoho Creator, then this is for you. Fill up the form below and if you want to be included in a case study, we will get in touch with you to get further details. So what are you waiting for? Tell us your story. Charles
                                              • Merge and Store v1 API depreciation

                                                Hi Zoho Writer users, The Merge and Store v1 API allows you to store the merged document in Zoho WorkDrive. The response of this API will be returned with the document's ID only after the merge is complete. In Deluge, the maximum timeout for operation
                                              • Zoho Creator Developer's Conference 2017 !!!

                                                We welcome all our Creator Developers! You're invited to join us for our annual Zoholics Developers conference August 29th–31st! This is your chance to get training and guidance on Zoho Creator from our most knowledgeable custom app builders.       Zoholics Developers is a three-day event where you'll participate in interactive workshops to hone your app-building skills, get questions answered by Creator experts with personal one-on-one sessions, and connect with other Creator developers from around


                                              Manage your brands on social media



                                                    Zoho TeamInbox Resources

                                                      Zoho DataPrep Resources



                                                        Zoho CRM Plus Resources

                                                          Zoho Books Resources


                                                            Zoho Subscriptions Resources

                                                              Zoho Projects Resources


                                                                Zoho Sprints Resources


                                                                  Qntrl Resources


                                                                    Zoho Creator Resources



                                                                        Zoho Campaigns Resources


                                                                          Zoho CRM Resources

                                                                          • CRM Community Learning Series

                                                                            CRM Community Learning Series


                                                                          • Kaizen

                                                                            Kaizen

                                                                          • Functions

                                                                            Functions

                                                                          • Meetups

                                                                            Meetups

                                                                          • Kbase

                                                                            Kbase

                                                                          • Resources

                                                                            Resources

                                                                          • Digest

                                                                            Digest

                                                                          • CRM Marketplace

                                                                            CRM Marketplace

                                                                          • MVP Corner

                                                                            MVP Corner





                                                                              Design. Discuss. Deliver.

                                                                              Create visually engaging stories with Zoho Show.

                                                                              Get Started Now