Jump to content

Recommended Posts

Hi Guys, 

 

I'm back, with some final (hopefully) questions on Reporting. Assuming the Data looks like this:  

image.png.dc41d4f3a8a2aa184d6398bfe0b01d3f.png

I can create Reports from the Item, Type, etc that's easy. 

What I'm struggling with is the following: 

1. Making a Report which is sorted by Type, but only where the Qty is above 0. So where Bread, Cheese and Crackers would be excluded.

 

2. Making a Report which shows the 'top 10' owned, and 'bottom 5' owned - based on qty field.

 

3. Making a Report which shows me the 'best' month (a) per product and [which month did I have the most of all items] and (b) the same in year. 

 

I'd appreciate any help or advice :)

 

Thanks!

N 

 

 

 

 

image.png

Link to post
Share on other sites
5 hours ago, Neil Scrivener said:

1. Making a Report which is sorted by Type, but only where the Qty is above 0.

Assuming that quantity cannot be negative, the only way that a quantity of a group can be 0 is if all the quantities in the group are 0. So simply start by performing a find for quantity > 0.

 

5 hours ago, Neil Scrivener said:

2. Making a Report which shows the 'top 10' owned,

I assume you mean the top 10 types by quantity? For this, you will need to first sort your records by Type and then omit any records after the 10th group. This can be done quickly using an adaptation of a method called Fast Summaries by Mikhail Edoshin.

Your table needs to have 2 summary fields: sTotal for totaling the quantity and sCount that counts some field that cannot be empty (e.g. ItemID).

Start by finding the items iyou want to report on and sorting them by Type, reordered by sTotal, descending. This groups the items by type and places the groups with the highest quantities at the top of the report.

Then make your script do:

# GO TO FIRST RECORD OF EACH GROUP, USING "FAST SUMMARIES"
Go to Record/Request/Page [ First ]
Loop
  Set Variable [ $i; Value:$i + 1 ]
  Set Variable [ $nextRecord; Value:Get ( RecordNumber ) + GetSummary ( Items::sCount ; Items::Type) ]
  Exit Loop If [ $nextRecord > Get ( FoundCount ) or $i > 10 ]
  Go to Record/Request/Page [ $nextRecord ] [ No dialog ]
End Loop
# OMIT EXCESS RECORDS
If [ $i > 10 ]
  Omit Multiple Records [ Get ( FoundCount ) - Get ( RecordNumber ) + 1 ][ No dialog ]
End If

 

I am afraid I did not understand #3. It sounds like there are several questions in there and each deserves its own thread.

 

Edited by comment
Link to post
Share on other sites

Thanks for this will give a go. 

Should I be creating a Script to run the Find, so that if additional value are created - or that the Find gets reset, it can be re-instated? 

Or is it the case that once Find has been activated, it's 'locked in'? 

Link to post
Share on other sites

I am not sure I understand the question. You said you wanted to produce a report. A script that produces a report will normally start by establishing a found set of the records to report on. 

 

Link to post
Share on other sites

Thanks for this, I've ran into two problems: 

The first is that when using Find, inserting >18 I'm getting a message saying "No records match this criteria". However >0 works perfectly. Why is this? 

The second is that I have a nicely laid out report when sorted by Type. I have a sub-summary with with Type heading, and then the Body contains the vegitables and quantities. When performing a Find (as per the working one, above), my lovely titles and headings are vanishing, and I'm getting hard and fast data. I guess this is because Find it showing 'Body' only - but when creating a Report (say a paper of PDF), I'd want to perform the Find, and then keep the nicities of my Header, Sub-Summary, Footer etc.... How would I do that? 

Thanks!

 

 

 

Link to post
Share on other sites

Got it! Thanks. 

For anyone else reading who experiences the same issues - I believe you need to: 

1. Perform the Find in your Criteria

2. Sort Records 

I'm going to make a script that does this, and then when clicked takes you to the Print option - which should package everything nicely up :)

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Similar Content

    • By tomp
      I'm having a problem getting BE_SMTPsend to successfully send an email with an attachment.
      No problem sending without an attachment, but when I add an attachment, I get an error 2 (not sure exactly what that means, but without the attachment, no error)
      These are the argument strings with and without attachments:

      I have tried both relative and direct file paths for the variable $attachment. Examples are:


      Both of them return an error code of 2.
      Since the 'send' without an attachment works, all the values of the fields/variables other than $attachment must be valid.
      Can anyone offer a suggestion as to what might be going on and what I might try to resolve this?
       
    • By Msaeed
      Hi All,
      As per mentioned on topic, in fact i would like to create icon ex. hour in case rigging guard the insert time.

    • By Solvax
      Hi,
      I'm trying to make a subsummary report with data from the current table and a related table.
      I never get to display the correct totals for the related table, and would therefore appreciate your help.
      First I'll try to explain the workflow:
      I have two tables called 'Voorraad_uit' (= outgoing stock) and 'Voorraad_in' (= incoming stock) which are related by delivery number.
      Data is first entered in 'Voorraad_in' (= incoming stock) and then related records are created in 'Voorraad_uit' when an incoming stock item is partly or completely shipped.  This second table contains mainly the outgoing amount and a unique outgoing delivery ID.

      As a consequence, one record in table 'Voorraad_in' (= incoming stock) can have one ore more related records in 'Voorraad_uit' (=outgoing stock).
      I want to make a subsummary report showing the total amount of incoming and outgoing units per product(name) by using the following layout structure:

      I tried two scenarios which each give me a part of the desired result.
      when I base the layout on 'Voorraad_in' (=incoming stock): I get the right totals for incoming deliveries I get all the incoming deliveries listed (also those without outgoing delivery) Body part 3 (see above) only shows one row also when there are more than one related outgoing transactions I get the wrong totals for outgoing deliveries (only based on one record) when I base the layout on 'Voorraad_uit' (=outgoing stock): I get the wrong totals for incoming deliveries I don't get all the incoming deliveries listed (only those with outgoing delivery) Body part 3 (see above) shows all the related outgoing transactions I get the right totals for outgoing deliveries Main goal is having the right totals for both incoming and outgoing deliveries..
      My layout is sorted ascending by (in mentioned order) productname, incoming delivery number and outgoing delivery number.
      The totals are calculated by using summary fields.
      I hope I'm on the right track and that the desired result is possible.. your help is much appreciated!
      Thanks in advance for your help.
      Regards,
      Solvax
    • By Steve Pfister
      Security Challenge when signing on to Paypal through Filemaker pro 18 web viewer.    I see the text "Security Challenge" but nothing else shows up... all is invisible, making it impossible to solve the security challenge and sign in....  Mac Pro..OS High Sierra 10.13  ....running Filemaker 18 .     I am having Java script issues I am assuming.   Has anyone else had this similar issue and solved it?
      Thank you in advance
      Steve
    • By Pio Soto
      Hi, I was wondering if it's possible to add some design to my email, 
      I have attached a sample of what I'm looking for but the idea I got is from my quickbooks email invoice.
      Thanks.

  • Who Viewed the Topic

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.