Hot Topic (More than 10 Replies) Counting in Reports (Read 1315 times)
SpencerWulwick
Senior Member
Members
*****
Offline



Posts: 677
Location: Wilton Manors, Florida
Joined: Jan 16th, 2005
Counting in Reports
Aug 21st, 2005 at 5:07pm
Print Post Print Post  
Hi -

I have a report that includes a persons choice of entree which is either Beef, Chicken or Fish.

At the end of the entree column I want a count of each selected entree such as:

B - 33
C - 168
F - 40

Any suggestions?

Thanks!
  

- Spencer

    ** Practice random kindness & senseless acts of beauty!
Back to top
IP Logged
 
Bob_Hansen
Senior Member
Members
*****
Offline


WOW, They have the Internet
on computers now!

Posts: 1861
Location: Salem, NH
Joined: Nov 24th, 2002
Re: Counting in Reports
Reply #1 - Aug 22nd, 2005 at 4:21am
Print Post Print Post  
Hi Spencer.

Add three invisible fields to report, not needed in form.
Add programming:
if selection = Beef, field1=1, else 0
if selection = Chicken, field2=1, else 0
if selection = Fish, field3=1, else 0

Add group totals for fields 1,2,3
  



Bob Hansen
Sesame Database Manager Professional
Sensible Solutions Inc.
Salem, NH
603-898-8223
Skype ID = sensiblesolutions
Back to top
IP Logged
 
SpencerWulwick
Senior Member
Members
*****
Offline



Posts: 677
Location: Wilton Manors, Florida
Joined: Jan 16th, 2005
Re: Counting in Reports
Reply #2 - Aug 22nd, 2005 at 6:26am
Print Post Print Post  
Hi Bob -

Once again, thanks for your help, but I still have a problem.

I added the 3 invisible columns and was able to complete the programming so that a "1" is entered in the appropriate column when that particular entree was chosen.

I also added Sums in the report footer to total the selections for each choice. BUT, it won't let me attach a label so all I get is 3 figures in the footer, something like 33 168 40.   It doesn't tell me which figure goes with which entree.  

So, how can I identify what each figure represents?
  

- Spencer

    ** Practice random kindness & senseless acts of beauty!
Back to top
IP Logged
 
SpencerWulwick
Senior Member
Members
*****
Offline



Posts: 677
Location: Wilton Manors, Florida
Joined: Jan 16th, 2005
Re: Counting in Reports
Reply #3 - Aug 22nd, 2005 at 3:14pm
Print Post Print Post  
OK -

I forgot about the "static" text boxes - so I used one of those before each "sum" to indicate what it is.  So now I get

B = 33   C = 168   F = 40

It's not "purty" like I wanted but at least it provides the information.  

I really wanted the figures below each other directly below the Entree column such as:  

B = 33
C = 168
F = 40

but don't see any way to do that.  If anyone knows of a way, to have more control over what appears where, I would appreciate knowing about it.

Also, the new report (generator/writer/whatever it's called) was mentioned quite a while ago.  Is there any word on when it will be available?

Thanks y'all!

Bob - I especially want to thank you once again for pointing me in the right direction.  While not "perfect" (by my own personal standards) I do at least have a viable, presentable report. Thank you - Thank you!!!
  

- Spencer

    ** Practice random kindness & senseless acts of beauty!
Back to top
IP Logged
 
Hammer
YaBB Administrator
Lanticans
*****
Offline


Fire bad. Tree pretty.

Posts: 3436
Location: Ohio
Joined: Nov 22nd, 2002
Re: Counting in Reports
Reply #4 - Aug 22nd, 2005 at 5:04pm
Print Post Print Post  
You can add additional Groups to get more Group Footer rows. This will allow you to do what you describe. Alternately, you can assemble all the labels and numbers into a single Unbound Value box with a <BR> between each label/number, which will create a new line.
  

- Hammer
The plural of anecdote is not data.
Back to top
IP Logged
 
SpencerWulwick
Senior Member
Members
*****
Offline



Posts: 677
Location: Wilton Manors, Florida
Joined: Jan 16th, 2005
Re: Counting in Reports
Reply #5 - Aug 25th, 2005 at 5:01am
Print Post Print Post  
Erika -

This raises several questions for me.

Similar to wanting the Beef, Chicken & Fish labels & sub-totals to come out one under each other in the footer, I also wanted to split the header Amount Paid into two lines.

1)  I tried adding another view header but it came out at the end of the report --- do I have to add a group (and I assume make it "invisible") to put the view header where I want it?

2) I tried putting Amount<br>Paid in the header but when the break occurred, the word "Amount" went to the beginning of the next line (instead of staying within the column) and then pushed everything forward after that.  I'm assuming that if I use the <br> in the footer, the same thing will happen.

3)  My columns are not staying lined up with the respective headings.  Any way to make it happen?  (Seems to me I did it in another report - but I looked at the report design and can't tell what made it come out right).

4) Any word on the new report generator/writer?

Thanks!
  

- Spencer

    ** Practice random kindness & senseless acts of beauty!
Back to top
IP Logged
 
Hammer
YaBB Administrator
Lanticans
*****
Offline


Fire bad. Tree pretty.

Posts: 3436
Location: Ohio
Joined: Nov 22nd, 2002
Re: Counting in Reports
Reply #6 - Aug 25th, 2005 at 11:57am
Print Post Print Post  
Quote:
Erika -

This raises several questions for me.

Similar to wanting the Beef, Chicken & Fish labels & sub-totals to come out one under each other in the footer, I also wanted to split the header Amount Paid into two lines.

1)  I tried adding another view header but it came out at the end of the report --- do I have to add a group (and I assume make it "invisible") to put the view header where I want it?


Adding a view is like adding another report. You want to add a Group, not a View.

Quote:
2) I tried putting Amount<br>Paid in the header but when the break occurred, the word "Amount" went to the beginning of the next line (instead of staying within the column) and then pushed everything forward after that.  I'm assuming that if I use the <br> in the footer, the same thing will happen.


It sounds like you are working in the View header instead of in the Group Header. The View Header is freeform and does not create table columns. The Group Headers and Footers will line up with your columns.

Quote:
3)  My columns are not staying lined up with the respective headings.  Any way to make it happen?  (Seems to me I did it in another report - but I looked at the report design and can't tell what made it come out right).


Same as 2.

Quote:
4) Any word on the new report generator/writer?


The new report features will come out with Version 2. No, I don't have a release date for Version 2.

  

- Hammer
The plural of anecdote is not data.
Back to top
IP Logged
 
SpencerWulwick
Senior Member
Members
*****
Offline



Posts: 677
Location: Wilton Manors, Florida
Joined: Jan 16th, 2005
Re: Counting in Reports
Reply #7 - Aug 25th, 2005 at 4:27pm
Print Post Print Post  
Erika -

Thanks to your help (in addition to Bob's), I am making great strides with my report - and my report capabilities in general.

You were, of course, right that I was using the View Header instead of the Group Header.  By changing to the Group Header, I was able to break (using <br>) my column headings the way I wanted them and the headings and columns are now aligned.  Bravo!

As for the Beef, Chicken & Fish labels & subtotals coming out under each other in the footer, I tried adding additional groups & footers but was unable to get the results I wanted.

That leaves me with one last (I hope) question.

You said earlier that:

Quote:
Alternately, you can assemble all the labels and numbers into a single Unbound Value box with a <BR> between each label/number, which will create a new line.


I added the unbound value box.  I assumed that I would "assemble all the labels and numbers" into that box using a programming statement but was unable to come up with one that would work.  Could you please be more specific about how to try this approach?

I am (as I'm sure other's are as well) eagerly looking forward to the release of Version 2.
  

- Spencer

    ** Practice random kindness & senseless acts of beauty!
Back to top
IP Logged
 
Bob_Hansen
Senior Member
Members
*****
Offline


WOW, They have the Internet
on computers now!

Posts: 1861
Location: Salem, NH
Joined: Nov 24th, 2002
Re: Counting in Reports
Reply #8 - Aug 25th, 2005 at 7:34pm
Print Post Print Post  
Spencer, you know the answer to that, you are just hung up with "assemble".  you have done this many times in the past.

Program a stirng of the fields and spaces.
varAssembledLine = "Beef:  " & @TN(BeefCountTotalField) & "     Chicken:  " & @TN(ChickenCountTotalField) & .........

You may want to replace some of the "       " spaces with @Text(.........) formulas to help keep alignment if the number of digits changes with the count totals.
  



Bob Hansen
Sesame Database Manager Professional
Sensible Solutions Inc.
Salem, NH
603-898-8223
Skype ID = sensiblesolutions
Back to top
IP Logged
 
Ray the Reaper
Global Moderator
Members
Lantica Support
*****
Offline


The One & The Only

Posts: 2482
Joined: Aug 20th, 2003
Re: Counting in Reports
Reply #9 - Aug 25th, 2005 at 7:51pm
Print Post Print Post  
Since you are doing the totaling of the entree choice in a summary calculation element and not in code, you need to assemble your unbound value box in the next group footer. If you get Inside Sesame, I know Tom explained this last issue. Page 15. Left hand column.

Ex. GF means Group Footer
GF2 Invisible Summary elements go here
GF1 Unbound value box here can use the values in the summary elements up above.

The reason for this is because a report section runs it's programming before it runs the summary calculations and breaks.

-Ray
  

Raymond Yoxall Consulting
ray.yoxall@gmail.com
ryoxall@lantica.com
Sesame Applications, Design and Support
Back to top
IP Logged
 
SpencerWulwick
Senior Member
Members
*****
Offline



Posts: 677
Location: Wilton Manors, Florida
Joined: Jan 16th, 2005
Re: Counting in Reports
Reply #10 - Aug 26th, 2005 at 1:19am
Print Post Print Post  
I give up.

I just can't seem to get the "programming" to work.

Thanks to everyone's help, though, I do have a viable report that is much more presentable than when I started.

I will eagerly wait for version 2 and hope that the report process is easier to use and more flexible. 

I have FAITH!!!!
  

- Spencer

    ** Practice random kindness & senseless acts of beauty!
Back to top
IP Logged