Alpha Video Training
Results 1 to 5 of 5

Thread: Sorting on calculated field

  1. #1
    Member Larry Gordon's Avatar
    Real Name
    Larry Gordon
    Join Date
    May 2008
    Location
    Worcestershire, UK
    Posts
    398

    Default Sorting on calculated field

    Hi, I know this subject has been posted on a number of times, but I still can't resolve my issue.

    I have attached an image of my current report. This report is based on a one-to-many set as it shows. However, I want to sort it in the order of the calculated field. I now know that this not possible, so I thought I'd set up a browse to do much the same thing as the report below, but then to 'post' the Grp tot field value to another table, which I could then sort by those values.

    Sadly, I couldn't get my browse to produce the same result as the report.

    I would welcome suggestions.

    Thanks

    Larry

    Ac_tots.jpg

  2. #2
    "Certified" Alphaholic MoGrace's Avatar
    Real Name
    Robin
    Join Date
    Mar 2006
    Location
    Los Angeles
    Posts
    3,584

    Default Re: Sorting on calculated field

    Hi Larry,
    Need a bit more info regarding the set links and the report groups. Can you make a sample & upload?
    Robin

    Discernment is not needed in things that differ, but in those things that appear to be the same. - Miles Sanford

  3. #3
    "Certified" Alphaholic
    Real Name
    Gregg Schmidt
    Join Date
    Mar 2001
    Location
    Milwaukee
    Posts
    1,243

    Default Re: Sorting on calculated field

    "Can't" is a horrible word when it comes to the Alpha world.
    Usually just a matter of what you want, and how much you want it.
    When you say "set", that suggests you are using dbf tables.
    While there is nothing wrong with that, sql makes it so much easier to
    accomplish what you want to do.
    The other missing part would be is this an on-demand report, or an automated report?

  4. #4
    Member Larry Gordon's Avatar
    Real Name
    Larry Gordon
    Join Date
    May 2008
    Location
    Worcestershire, UK
    Posts
    398

    Default Re: Sorting on calculated field

    Thanks for the replies. I'll try to make a sample but I'll have to find out how to do that first - my application has been built over many years and is enormous. Meanwhile I have attached a screen shot of the report in edit mode - its a simple little report.

    Yes, I am running DBF's - I looked into transferring to SQL as one or two of my tables are now quite large, but I was advised that it would be difficult to transfer from DBF to SQL.

    I guess the report is 'on demand'. I want to run it every few months in order to produce a list of my top spending customers. The report that I initially set up is based on a set with the top table being the Cust_mach, which has one to many links with its child, the Billing table.

    I also have another table called Acc, which is not linked to the above. This simple table just has an Account field, a Customer field and a numeric field called Balance. After I found that I could not sort my report by a calculated field, I thought I would run a browse to produce the same results as the above report, but my intention was to somehow post the 'Grp tot' from that browse into the Balance field in the Acc table. I would then simply sort on the Balance field.

    Hope this helps.

    Report.jpg

  5. #5
    "Certified" Alphaholic Tom Henkel's Avatar
    Real Name
    Tom Henkel
    Join Date
    May 2002
    Location
    New Jersey, USA
    Posts
    1,858

    Default Re: Sorting on calculated field

    Larry,

    Why not create a new set with the ACC table as a 1 to 1 child to the Cust_mach table? Then copy the report to the new set.

    There is no reason it can't be part of the set, then the field is readily available.

    We create sets for specific reports/browses/forms all the time. They do not take up that much space, and then you have the information right at your finger tips.

    Tom

Similar Threads

  1. Sorting by a Calculated Field in a Report
    By tom@statesidedata.com in forum Alpha Five Version 10 - Desktop Applications
    Replies: 13
    Last Post: 01-22-2011, 01:22 AM
  2. Deleting and Sorting Calculated Fields in DragDrop List
    By Chuck Bytes in forum Alpha Five Version 10 - Desktop Applications
    Replies: 3
    Last Post: 01-21-2010, 08:45 PM
  3. Sorting by Calculated field values
    By Larry Gordon in forum Alpha Five Version 9 - Desktop Applications
    Replies: 2
    Last Post: 05-24-2008, 02:30 PM
  4. Sorting on crosstab calculated fields
    By Don Hutchinson in forum Alpha Five Version 6
    Replies: 0
    Last Post: 11-03-2004, 04:09 AM
  5. sorting and calculated fields
    By Ian_Edwards in forum Alpha Five Version 6
    Replies: 1
    Last Post: 07-31-2004, 03:41 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •