OpenOffice.org Forum at OOoForum.orgThe OpenOffice.org Forum
 
 [Home]   [FAQ]   [Search]   [Memberlist]   [Usergroups]   [Register
 [Profile]   [Log in to check your private messages]   [Log in

ext report designer summary function

 
Post new topic   Reply to topic    OOoForum.org Forum Index -> OpenOffice.org Base
View previous topic :: View next topic  
Author Message
klausk
General User
General User


Joined: 28 Jul 2007
Posts: 41
Location: germany

PostPosted: Mon Jul 30, 2007 12:52 am    Post subject: ext report designer summary function Reply with quote

is it possible to generate a summary over all values fro, column of the recordsection with the new reportdesigner version 0.5. for example the summary of all records of the field "area_ha".
Back to top
View user's profile Send private message
IRF1404
General User
General User


Joined: 25 Jan 2007
Posts: 40

PostPosted: Mon Jul 30, 2007 5:28 pm    Post subject: Reply with quote

If you mean that you want the arthimetic sum of all of the data in a column in your database, you can perform this operation in a report. See http://searchenterpriselinux.techtarget.com/tip/0,289483,sid39_gci1260586,00.html#report-specific%20fields

I hope this helps.
_________________
DD the Newbie
Back to top
View user's profile Send private message
DrewJensen
Super User
Super User


Joined: 06 Jul 2005
Posts: 2616
Location: Cumberland, MD

PostPosted: Mon Jul 30, 2007 7:10 pm    Post subject: Reply with quote

yeah, of course your can do this in the query that feeds the report designer and with the report wizard that was your only option.

With the new report designer it is not, you can do it within the report itself.

I'm trying to put together a simple tutorial for RD but can give you a rough idea of how to do this - actually, what follows is a quote from the main Sun developer of Report Designer, Ocke Janssen

Quote:

For example you want to count something you have to create a new
function and give it a name let's say PopCount (to count the population
of a country). In the next row of the property browser you'll enter the
function [PopCount] + [Population] As you can see, all names are quoted
with []. The initial value in this case is [Population]. Population is
the field/column name out of my database. All formulas should follow the
style defined in OpenFormula
http://www.oasis-open.org/committees/download.php/23519/openformula-20070414.odt





If that doesn't make a lot of sense I'll try to expand on it - The 'How to' I am working on will definitely go into more details, with examples, on this...

As for actual aggregate functions - they are in the works, but I don't think any will be available before 2.4 release, at least that is the impression I get from watching the activity on the issue tracker.

EDIT - one last point. You can create functions that are report wide and limited to a group. So you expanding on Ocke's example you could count both the population for the whole earth, and if you had a grouping on continent you could also count the population for each of these, and so on down the line.

SECOND EDIT - I'll leave the URL for the OASIS document, since it was in the intitial email, but if you retrieve it and go through it don't be caught by thinking the functions described in it are available for the Report Designer ( trust me I killed more then a few hours on this )- they are intended for a spreadsheet and most will NOT function in the Report Designer - although some do, this is another item I am trying to get together for the How to: Which of those functions described in the document do work and which do not...so far, most do not.
_________________
Blog - http://baseanswers.spaces.live.com/
Back to top
View user's profile Send private message Send e-mail Visit poster's website
klausk
General User
General User


Joined: 28 Jul 2007
Posts: 41
Location: germany

PostPosted: Mon Jul 30, 2007 11:42 pm    Post subject: Reply with quote

hallo

Quote:
http://searchenterpriselinux.techtarget.com/tip/0,289483,sid39_gci1260586,00.html#report-specific%20fields



the sql example works fine, but my problem is to put the sum into a recordsection. the report has two groupfields and is based on a parameterquery.


Quote:
So you expanding on Ocke's example


I will search the document for the function

thanks
Back to top
View user's profile Send private message
DrewJensen
Super User
Super User


Joined: 06 Jul 2005
Posts: 2616
Location: Cumberland, MD

PostPosted: Tue Jul 31, 2007 7:21 am    Post subject: Reply with quote

?

Do you mean that you want to have the report manipulate this calculated field in the query?

In other words - in the query you use the SUM function to get an aggregate for the entire table ( result set ), but then in the report designer you want to add this field into a group section and have the value changed to only reflect the sub set of records valid for the group?

If this is what you mean, then NO you can not do that.

You could use GROUP BY in your query to achieve this, or you could use the technique shown above for the Report Designer.
_________________
Blog - http://baseanswers.spaces.live.com/
Back to top
View user's profile Send private message Send e-mail Visit poster's website
klausk
General User
General User


Joined: 28 Jul 2007
Posts: 41
Location: germany

PostPosted: Sat Aug 04, 2007 11:50 am    Post subject: Reply with quote

hallo andrew,

Quote:
EDIT - one last point. You can create functions that are report wide and limited to a group. So you expanding on Ocke's example you could count both the population for the whole earth, and if you had a grouping on continent you could also count the population for each of these, and so on down the line.


with this hint and the above shown file i habe been able to realize the functions.

http://www.rhenschel.homepage.t-online.de/version6.odb/

thanks a lot
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    OOoForum.org Forum Index -> OpenOffice.org Base All times are GMT - 8 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group