Alpha Software Mobile Development Tools:   Alpha Anywhere    |   Alpha TransForm subscribe to our YouTube Channel  Follow Us on LinkedIn  Follow Us on Twitter  Follow Us on Facebook

Announcement

Collapse

The Alpha Software Forum Participation Guidelines

The Alpha Software Forum is a free forum created for Alpha Software Developer Community to ask for help, exchange ideas, and share solutions. Alpha Software strives to create an environment where all members of the community can feel safe to participate. In order to ensure the Alpha Software Forum is a place where all feel welcome, forum participants are expected to behave as follows:
  • Be professional in your conduct
  • Be kind to others
  • Be constructive when giving feedback
  • Be open to new ideas and suggestions
  • Stay on topic


Be sure all comments and threads you post are respectful. Posts that contain any of the following content will be considered a violation of your agreement as a member of the Alpha Software Forum Community and will be moderated:
  • Spam.
  • Vulgar language.
  • Quotes from private conversations without permission, including pricing and other sales related discussions.
  • Personal attacks, insults, or subtle put-downs.
  • Harassment, bullying, threatening, mocking, shaming, or deriding anyone.
  • Sexist, racist, homophobic, transphobic, ableist, or otherwise discriminatory jokes and language.
  • Sexually explicit or violent material, links, or language.
  • Pirated, hacked, or copyright-infringing material.
  • Encouraging of others to engage in the above behaviors.


If a thread or post is found to contain any of the content outlined above, a moderator may choose to take one of the following actions:
  • Remove the Post or Thread - the content is removed from the forum.
  • Place the User in Moderation - all posts and new threads must be approved by a moderator before they are posted.
  • Temporarily Ban the User - user is banned from forum for a period of time.
  • Permanently Ban the User - user is permanently banned from the forum.


Moderators may also rename posts and threads if they are too generic or do not property reflect the content.

Moderators may move threads if they have been posted in the incorrect forum.

Threads/Posts questioning specific moderator decisions or actions (such as "why was a user banned?") are not allowed and will be removed.

The owners of Alpha Software Corporation (Forum Owner) reserve the right to remove, edit, move, or close any thread for any reason; or ban any forum member without notice, reason, or explanation.

Community members are encouraged to click the "Report Post" icon in the lower left of a given post if they feel the post is in violation of the rules. This will alert the Moderators to take a look.

Alpha Software Corporation may amend the guidelines from time to time and may also vary the procedures it sets out where appropriate in a particular case. Your agreement to comply with the guidelines will be deemed agreement to any changes to it.



Bonus TIPS for Successful Posting

Try a Search First
It is highly recommended that a Search be done on your topic before posting, as many questions have been answered in prior posts. As with any search engine, the shorter the search term, the more "hits" will be returned, but the more specific the search term is, the greater the relevance of those "hits". Searching for "table" might well return every message on the board while "tablesum" would greatly restrict the number of messages returned.

When you do post
First, make sure you are posting your question in the correct forum. For example, if you post an issue regarding Desktop applications on the Mobile & Browser Applications board , not only will your question not be seen by the appropriate audience, it may also be removed or relocated.

The more detail you provide about your problem or question, the more likely someone is to understand your request and be able to help. A sample database with a minimum of records (and its support files, zipped together) will make it much easier to diagnose issues with your application. Screen shots of error messages are especially helpful.

When explaining how to reproduce your problem, please be as detailed as possible. Describe every step, click-by-click and keypress-by-keypress. Otherwise when others try to duplicate your problem, they may do something slightly different and end up with different results.

A note about attachments
You may only attach one file to each message. Attachment file size is limited to 2MB. If you need to include several files, you may do so by zipping them into a single archive.

If you forgot to attach your files to your post, please do NOT create a new thread. Instead, reply to your original message and attach the file there.

When attaching screen shots, it is best to attach an image file (.BMP, .JPG, .GIF, .PNG, etc.) or a zip file of several images, as opposed to a Word document containing the screen shots. Because Word documents are prone to viruses, many message board users will not open your Word file, therefore limiting their ability to help you.

Similarly, if you are uploading a zipped archive, you should simply create a .ZIP file and not a self-extracting .EXE as many users will not run your EXE file.
See more
See less

Creating a Report with varying fields

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    #16
    Re: Creating a Report with varying fields

    Originally posted by gaby_h View Post
    Al, Please see attached. I added a 2nd report based on grouped data. With 500 records in the source table I didn't notice a difference in performance. When I have some spare time I'll load a few thousand records more and test for the difference in speed. Thanks for the suggestion.
    I would think it may take 1000's or 10,000's of records to see the difference.

    Or there may not be one.....

    Or since I just used an append to append sales to itself and ran it a few times, I now have 34,880 sales records I'm finding that the sum_table is faster. It takes 10 seconds to render vs 22 seconds on the sales based report.... Not what I expected at all.. Guess that why we test...

    Let me know your results.
    Al Buchholz
    Bookwood Systems, LTD
    Weekly QReportBuilder Webinars Thursday 1 pm CST

    Occam's Razor - KISS
    Normalize till it hurts - De-normalize till it works.
    Advice offered and questions asked in the spirit of learning how to fish is better than someone giving you a fish.
    When we triage a problem it is much easier to read sample systems than to read a mind.
    "Make it as simple as possible, but not simpler."
    Albert Einstein

    http://www.iadn.com/images/media/iadn_member.png

    Comment


      #17
      Re: Creating a Report with varying fields

      Same result here. With 248,000 records; grouped data: 275 sec, Tablesum: 95 sec, nearly 3x faster

      Comment


        #18
        Re: Creating a Report with varying fields

        Gaby,
        Now realizing that tablesum is the faster.....maybe try dbsum as that has always been faster than tablesum I believe (usually results in at least twice the speed for me so far). If a filter has to be used then maybe a filtered index would work (has for me in a unique circumstance when I needed one--tend to shy away from them due to some statements made here on the board though).
        Mike
        __________________________________________
        It is only when we forget all our learning that we begin to know.
        It's not what you look at that matters, it's what you see.
        Henry David Thoreau
        __________________________________________



        Comment


          #19
          Re: Creating a Report with varying fields

          Hi Mike:
          You are right DBSum() is much faster than TableSum(): With DBSum() takes 10sec, vs 95sec with Tablesum(). The only thing is that my expression in the DBsum(....) must be wrong because it's returning the wrong amounts.
          Would appreciate it if someone can take a look at TrendedRep_calc2 (where my DBsums are). Thanks

          Comment


            #20
            Re: Creating a Report with varying fields

            Gaby,
            No matter what dates I choose, your tablesum is not working. The dbsum seems to be. You are going to have to tell us exactly what date(s) to use, and what your results are for tablesum and dbsum and what they are supposed to be as well. Maybe not all the results, but maybe the first 3 or 4.
            Mike
            __________________________________________
            It is only when we forget all our learning that we begin to know.
            It's not what you look at that matters, it's what you see.
            Henry David Thoreau
            __________________________________________



            Comment


              #21
              Re: Creating a Report with varying fields

              Mike: start with the Form "Trended Report", it has 4 buttons:
              1-Grouped: for report with grouped data - returns the right amounts but don't use it, takes several minutes to get the results.
              2-Tablesum: for report using the tablesum funtion, returns the right results. just enter start date like 3/1/2006, and endate like 10/31/2006 (cannot go more that 12 months); records in the data table go from Aug 2005 to Feb 2009.
              3-DBSum: for report using DBsum function.
              4-Dates: - ignore, this is just to initialize the date variables when testing
              I Also have a browse based on the data table to dble check monthly amounts.
              Attached are 2 pdf: 1 with Tablesum() that's what you should get when using Tablesum button, 1 with DBsum() that's what you should get using the DBsum button for the period 1/1/2007 to 12/31/2007. Tablesum() returns the correct amounts (can be checked against the amounts produced by the browse; just filter for a specific product, specific month and specific year. Amounts returned by the DBsum() are not correct.

              Comment


                #22
                Re: Creating a Report with varying fields

                extra post....just hate when I hit the wrong key!
                Last edited by MikeC; 10-11-2009, 11:21 PM.
                Mike
                __________________________________________
                It is only when we forget all our learning that we begin to know.
                It's not what you look at that matters, it's what you see.
                Henry David Thoreau
                __________________________________________



                Comment


                  #23
                  Re: Creating a Report with varying fields

                  Hi Gaby,
                  Finally on here tonight. Took a quick look and a couple of things.

                  Your sales1 had "Sales" instead of "Amount" (unless I messed it up!)

                  Use a filtered index as I said--such as
                  Code:
                  BETWEEN(DATE,VAR->ZSTART,VAR->ZEND)
                  Seems to result in the same numbers.

                  Later--wonder if when the variable has no values (not as of yet set) if it will cause issues---if it does, use an if() function so that it only filters if there are values in the variables. May have to declare these as well as global in say your autoexec as what happens to the index when the variable does not exist yet--corruption?? Others may have insight to this. Regardless easy enough to make sure I guess to make it safe.
                  Mike
                  __________________________________________
                  It is only when we forget all our learning that we begin to know.
                  It's not what you look at that matters, it's what you see.
                  Henry David Thoreau
                  __________________________________________



                  Comment


                    #24
                    Re: Creating a Report with varying fields

                    Mike: Much appreciate the time you are spending on this to help me.
                    Originally posted by MikeC View Post
                    Your sales1 had "Sales" instead of "Amount" (unless I messed it up!)
                    No, you didn't mess up. I changed the field's name to Amount and forgot this one, sorry about that.

                    Originally posted by MikeC View Post
                    Use a filtered index as I said--such as
                    Code:
                    BETWEEN(DATE,VAR->ZSTART,VAR->ZEND)
                    Seems to result in the same numbers.
                    I am not familiar with filtered index. Do you mean I create an index with the Between() expression? If so, I am confused on how I can use it in the DBsum(). There is definetely something wrong with the way I defined my index ( Product+Month(Date)+Year(date) ).
                    If you are getting the right numbers would you be kind enough to zip the sample file or post what the index should be and what should go in the DBsum expression; like: DBSum("Sales, " what index here", "what expression here", "Amount") for a month say month3. I have spend the entire evening on this with nooooo result.
                    Thanks again.

                    Comment


                      #25
                      Re: Creating a Report with varying fields

                      Here is a screenshot Gaby. When you defined your index you set the order...now set the same filter you used basically in your tablesum.

                      Mike
                      __________________________________________
                      It is only when we forget all our learning that we begin to know.
                      It's not what you look at that matters, it's what you see.
                      Henry David Thoreau
                      __________________________________________



                      Comment


                        #26
                        Re: Creating a Report with varying fields

                        Thanks Mike, works perfectly now. You are a Champ. Thanks again for being patient with me.

                        Comment


                          #27
                          Re: Creating a Report with varying fields

                          Always nice to be able to help provide a solution for someone.

                          Curious if the dbsum still only takes the 10 seconds with the filter added as compared with the 95 for Tablesum and 275 for the Grouping method results you had given before.
                          Mike
                          __________________________________________
                          It is only when we forget all our learning that we begin to know.
                          It's not what you look at that matters, it's what you see.
                          Henry David Thoreau
                          __________________________________________



                          Comment


                            #28
                            Re: Creating a Report with varying fields

                            I didn't notice any difference.

                            Comment


                              #29
                              Re: Creating a Report with varying fields

                              Hello Stan,

                              I just wanted to say thanks. I did a search of the forum and found this post. It solved all my crosstab issues.

                              When I read your reply about appending the crosstab data into another table I said "of course, why didn't i think of that". I now no longer get the error messages on my pre-defined form and report because of non-existent fields. Also the append script worked like a charm.

                              Thanks again.

                              Comment

                              Working...
                              X