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

count syntax

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

    count syntax

    I'm trying to create report that counts unique entries of a field.

    For that field I have this: count(Data_Sku,GRP->Group 1)

    This gives me the total number of entries for that field but I need the count of unique entries instead.

    For example, the Data_SKU field has these as entries:
    1234
    ABCD
    1234
    1234
    1234
    ABCD

    It should yield a count of 2

    What do I need to change for the expression builder to make it work ?

    #2
    Re: count syntax

    If the report is sorted by the Data_sku field couldn't you get the count by defining a total calculation for something like this:

    if(data_sku = previous("data_sku"), 0, 1)

    i.e. return a zero if the current sku is the same as the previous; return a 1 if it's not. Then put this calc expression in a second expression that totals it for the report. (grand total). You should get the number of times the sku changed... i.e. the number of unique sku's ... I haven't had a chance to test this, so let us know how it turns out.

    -- tom

    Comment


      #3
      Re: count syntax

      I'm not sure if I did it right but no luck.

      Ultimately, this is for an employee productivity report. It reports, by employee, how well they performed in an inventory audit. So, I'm looking for the count of unique Data_SKU's per employee.

      I have a different report where each Data_SKU has a separate line. If I could get a count of the lines in that report, it work give me the number I need. It used the expression:
      blank_duplicate(Captured_Data->Data_Sku,GRP->Data_sku)

      yet another report can give me the grand total number of unique skus. The expression it uses is this:
      count(CAPTURED_DATA->Data_sku,grp->Grand,grp->data_sku)

      A combination of the two formulas seems like it would work but I'm perplexed.

      Comment


        #4
        Re: count syntax

        Some sample data would help us help you.

        In the meantime, here's an example using a two table set. Hope it helps.

        I was unable to develop a single expression that met your requirements. So, my solution takes a different approach. I've put a field in the parent table that will hold the number of different sku's. This field is used in the report.

        Before running the report the heavy lifting is done by a script that steps through the child table counting distinct sku's and updating the related parent table record.

        The report shows the number of distinct sku's in a group footer for each employee.
        Last edited by Tom Cone Jr; 07-15-2010, 05:10 PM.

        Comment


          #5
          Re: count syntax

          Here's the database.
          http://inventoryscience.com/Vista/SSP_V_1101.zip

          The database is ScanShark_Data_Processing.ADB

          On opening, you'll need to click the "Advanced" button to allow you to access the control panel.

          The table is "Captured_Data.DBF" and the report is "User-Stats".

          You'll see from the data that Betty has 2 unique SKU's and John has 3 unique SKU's.

          Thanks a bunch.

          Comment

          Working...
          X