Jump to content

can you use two sub summaries in a report layout


littlered136
 Share

This topic is 2568 days old. Please don't post here. Open a new topic instead.

Recommended Posts

Hi

 

Is it possible to have two sub summaries in a report. I have two in my report layout but only one shows up. 

 

I am trying to get the crowd report all units to sort it by date and then under the date display some information that is then sorted by unit. 

 

Is this not possible. I did think about putting the unit section in the body above the scene details, But I don't want it to repeat the date and unit several each time there is a scene.

 

Thanks

 

Sarah

 

Crowd Breakdown Template.fmp12.zip

Link to comment
Share on other sites

Hi

Is it possible to have two sub summaries in a report. I have two in my report layout but only one shows up.

I am trying to get the crowd report all units to sort it by date and then under the date display some information that is then sorted by unit. 

 

If you have two sub-summary parts – one for date, one for unit – you also must sort by date and unit.

 

A sub-summary part whose break field isn't used in the sort order doesn't appear (which is probably what you are experiencing).

Link to comment
Share on other sites

Hi Eos

 

I have the first sub summary set to date and the second sub summary set to unit already? Is this what you meant, or did you mean somewhere else?

 

Many Thanks for your help so far, much appreciated....

 

Sarah

Link to comment
Share on other sites

Hi Sarah –

 

I have the first sub summary set to date and the second sub summary set to unit already? Is this what you meant, or did you mean somewhere else?

 

indeed you have, but did you read the bit about the found set needing to be sorted for the sub-summary parts to appear? If the found set isn't sorted by a break field (as defined in the/a sub-summary part), displaying it wouldn't make sense because there is no useful information to be had.

 

Best to write a report script that finds the records within the required date range, then sorts by date and unit. 

 

Oliver

Link to comment
Share on other sites

Hi Oliver

 

I was not sure quite what part you had meant as I am still very much a novice with filemaker pro, but now I get what you mean within the sub summary part now. 

 

I will go have a go. I have not written many scripts, so i am going 

 

Once again thank you very much

 

Sarah

Link to comment
Share on other sites

Hi Oliver

 

I think I might need a bit more help in understanding what I need to do. I thought I had understood what I needed to do if I am not adjusting the script that creates the report. 

 

I cannot seem to work out what I need to do to get it to display a 'banner' like the date 'banner' underneath the date 'banner' I wanted it to show the date, then underneath show the unit then all the information for that unit under that date, then list the unit 'banner' again still under that date and then all the scenes for that unit. Does that make sense. 

 

I am sorry I am not understanding what I need to do or what you are trying to tell me to do. I am still very very new to this and have tried for the past few hours to fiddle around to see if I can figure it out, but I still seem to be hitting a wall. Any further help is much appreciated from yourself or anyone.

 

Thanks

 

sarah


Even if I delete the date sub summary thinking the unit one wold show up, it doesn't..... I am not understanding why it will do it for the date field but not the unit field??

 

thanks

 

sarah

Link to comment
Share on other sites

Does that make sense.

 

Yes (though not 100% …  :smile: ). I'm not sure about the banner business.

 

See if the attached file does what you need (in a stripped-down way), or at least comes so close that you can see how and where to make the necessary adjustments.

 

Be aware that you need to execute the sort script (or sort manually) to actually see both sub-summaries.

DateAndUnit_Summaries_eos.fmp12.zip

Link to comment
Share on other sites

Hi

 

I am failing to see how mine is different to yours.. I have a sub summary by date and leading and a sub summary by unit and leading... 

 

I am sorry to not see it!!

 

and by banner I mean exactly how you showed it in your example, so it listed the date, then in another row listed the unit then all the info for that unit for that day , then moved onto the next unit. 

Link to comment
Share on other sites

Sarah –

 

what Lee said. Key to make sub-summaries work is applying the correct sort order (which can comprise multiple fields); without a sort, there's nothing to group (break).

 

Here's a quick checklist for a typical report:

 

1. Create layout with sub-summary parts.

 

2. Find desired records.

 

3. Sort by all fields that are used in the sub-summary parts you want to appear, in the order the sub-summary parts are stacked in the layout.

 

In your case, this means you need to sort by date, then unit.

 

4. (often overlooked) Make sure layout is in List view!

Link to comment
Share on other sites

Hi

 

So the way I have been doing it from scene details and hitting the all units button will not work... I thought in that script I had asked it to do it by date then unit??? 

 or is the way you kited it above how to structure my script.. sorry both for being very slow with this.. I am just trying to understand it all so it makes sense as I do it...

 

thanks again for the help, it is very much appreciated you giving your time to answer.

 

thansk

 

sarah

Link to comment
Share on other sites

Hi

 

So I redid a layout from scratch Layout 17......and put it as a list only. It still would not show up the unit section even when not using the button in scene details. i even did a report script the same as your example and had it as date and unit and still no unit sub summary showing up...

 

I even made sure within the scipt for the all units one the sort has date and then unit as the sort options..

 

 

Crowd Breakdown Template backup copy.fmp12.zip

Link to comment
Share on other sites

Unless I'm mistaken (well, it's a lengthy script), the All Units Report script in your posted file has one Sort Records step, and that sorts by date only, not by unit.

 

And points 2 - 4 would more or less be the basic outline of a script (where #4 is sorta superfluous, since for a dedicated report layout, you could/would just deactivate the other views).

Link to comment
Share on other sites

So I redid a layout from scratch Layout 17......and put it as a list only. It still would not show up the unit section even when not using the button in scene details. i even did a report script the same as your example and had it as date and unit and still no unit sub summary showing up...

 

Well, it works for me. After going to layout #17 and calling the sort script, I see records sorted descending by date, and within each date by units (also descending).

 

Your body part is a bit large, though … (which kinda messes up the list effect). If the fields there really are just one-liners, you can make it much smaller; if, on the other hand, you may need the space, make the fields larger and use the slide options (need Preview mode to see the effect) to make them occupy just as much vertical space as necessary.

 

If part and field size are merely due to the layout being a quick mock-up job, forget what I said (or memorise it for future use … :-)

Link to comment
Share on other sites

It is indeed a lengthy script. It was written by someone for the unit date report and I was basically using that and just changing it a bit I had hoped for the all units report. For the sort part of the script I made sure the sort is date then unit.

 

In layout 17 I know it is too large at the moment as agree leaving it like this would look messy...... I would be putting in other fields, but thought I would just try it to see if it worked first before inserting the rest of the field... when You say you went to layout 17 and called the sort script.. what does this mean.. how do you do that when the layout is open???. I can avoid the button on the scene details page if I can get it to work that way.

 

I really am appreciating all your guidance you are giving me

Link to comment
Share on other sites

Hi Oliver

 

I made a button in scene details to perform a script with the script that was working for you and now it works and shows up. Thank you sooo much for your patience with this and helping me understand what I needed to do rather then just doing it. It has really helped me understand what was going on. Now I am going to try to work out in the script how to get it to display the units in the order I want them so main then 2nd etc etc as think it grabs them as they are put into the records.

 

Again thank you soooo much.

 

Sarah

Link to comment
Share on other sites

Hi Sarah –

 

It is indeed a lengthy script. It was written by someone for the unit date report and I was basically using that and just changing it a bit I had hoped for the all units report. For the sort part of the script I made sure the sort is date then unit.

 

If it works, it works, but it surely isn't the optimal script (lots of repetition there that accounts for its length), which possibly has to do with a sub-optimal data structure.

 

With the correct data structure in place and a layout ready, most report scripts are really as simple as outlined above: there will be a table that already has all the data you need for the report, so what's left is finding the right records and sorting them. Maybe set some layout variables and do other fancy stuff, but that's already the icing part. (I also noted that the script manipulates a lot of data before showing the report, which – as mentioned above – shouldn't be necessary, strictly speaking.)   

 

Again thank you soooo much.

 

You're very welcome.

 

When I said “called the script" – all scripts that are checked in the Manage Scripts window show up in the menu and can be chosen there, and you can call the first 10 by pressing the Cmd-digit shortcut.

 

But that is not necessarily something you can use; as I said, any sorting to be done would be part of a larger report script, like the one you trigger with the popover for Unit Date Report (looks nice, btw).

 

Anyway, glad you got it working; don't hesitate to come back if you have other issues.

 

Oliver

Link to comment
Share on other sites

Hi Oliver

 

No I agree... I am going to reword the scripts as they seemed very long to me too and will give me a chance to leave and test it in a more simple format. After your help today and seeing as you say how easy it was to do a script and get it working... eventually once I understood the principles.....

 

I worked out how to get it to sort the values of the units as well in the order I want... now I will just made a button similar to the others for the scene details page and add some totals on the bottom and it is doing exactly what I want it to.. well at the moment it is making the date strip super wide, but before I come back on here I want to have a proper go at trying to fix it myself on first, see if I can see the problem.

 

Pnce again thank you for your patience and great teaching style. 

 

Sarah

Link to comment
Share on other sites

Hi Oliver.

 

So I have tried to work out on the layout of the all report button and it for some reason when there is a gap at the bottom extends the date sub summary box, I have tried to tag the break over pages option, but it still seems to do it. I am trying to get rid of it as it takes longer in the printer to print out color blocks at the bottom we don't need. Any ideas why it is doing that??

 

thansk

 

sarah


.

Crowd Breakdown Template backup copy.fmp12 2.zip

Link to comment
Share on other sites

Sarah –

 

please name exactly the scripts, layout, fields etc. you're having a problem with. At the moment, I have no idea which layout and script you're referring to.

Link to comment
Share on other sites

oh yes sorry that does help.. 

 

when you click on the all units button in the scene details, when it generates the report and you are in preview or save it as a PDF the date bar which is grey seems to extend down to the bottom of the page. I have attached a screen grab to show exactly the part I mean. Does this help to make more sense now???

 

so the section is the sub summary by date. The layout would be crowd report all units and the script it uses to generate it from the scene details all unit report button is the Report sort button trigger. 

 

Thanks

 

Sarah


.

post-110939-0-78658400-1405596220_thumb.

Link to comment
Share on other sites

You could try to modify the date sub-summary part by checking the “Add page break before each occurrence".

 

You will need more paper (or produce longer PDFs), but on the other hand the parts that belong together stay together.

Link to comment
Share on other sites

This topic is 2568 days old. Please don't post here. Open a new topic instead.

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
 Share

×
×
  • Create New...

Important Information

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