[prev in list] [next in list] [prev in thread] [next in thread] 

List:       koffice
Subject:    Re: Kspread question/help
From:       Marc Heyvaert <marc_heyvaert () yahoo ! com>
Date:       2004-09-01 10:23:24
Message-ID: 20040901102324.80870.qmail () web41506 ! mail ! yahoo ! com
[Download RAW message or body]

Hello,

--- Nicolas Goutte <nicolasg@snafu.de> wrote:

> The easiest would be with SUMIF but it has been
> introdiced only very recently:
> http://bugs.kde.org/show_bug.cgi?id=81026
> 
> As for a workaround, I do not know.
> 

I think the following procedure is a possible
workaround, but I can not test right now as I don't
have KDE/KOffice on this machine:

Create a column to hold either 0 if the value is to be
ommited from sum and 1 or whatever number if it is to
be included.

With the "search" function you can search for a
'string' within another. Supposing that you can enter
cell references for these strings (seems logical but
as I said I can't test right now) and that when the
string is not found this function returns zero as the
offset (again I can't test and the documentation is
not clear about this), you could use this function to
fill the extra column.

The next step is to use another column  for an
IF...THEN...ELSE construction.

So in your this case something like :

IF (the value in the 'test' column == 0) THEN (put
zero in this cell) ELSE (put the number from column X)

Copy this formula down and you can sum that straight
away for your first subresult.

If you need several subtotals depending on several
strings, you have to introduce 2 columns like this for
every 'type' of figure that you want to sum.

If there are a lot of different 'types' a better
workaround is to sort the lot and to add a 'sum'
function for each category by hand, as you scroll down
and scan the document.

Marc
> 
> On Tuesday 31 August 2004 21:50, Danny Angelo
> Carminati Grein wrote:
> > possible to do something like find rows that have
> text "text" in X col
> > cells?
> >
> >      Like this:
> >
> >      A        B
> > 1  10  text
> > 2  -5   other
> > 3  -6   text
> > 4  1    text
> > 5  18 other
> >
> >  What I want is to locate all rows that have
> "text" in column B ..    then
> > i will calculate the sum of these row but from
> column A ..  in this case, I
> > need get this result:
> >
> >   ...  C             D
> > 10  text        other
> > 11  15          13
> >
> > where 15 == sum of all cells relative to text
> "text" and 13 == sum of all
> > cells relative to text "other" ...
> >
> >  This is because I need do a sheet that will
> separate types of expenses and
> > do especial calcs with these...
> >



		
_______________________________
Do you Yahoo!?
Win 1 of 4,000 free domain names from Yahoo! Enter now.
http://promotions.yahoo.com/goldrush
____________________________________
koffice mailing list
koffice@mail.kde.org
To unsubscribe please visit:
https://mail.kde.org/mailman/listinfo/koffice
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic