Thread View: comp.apps.spreadsheets
1 messages
1 total messages
Started by Marshall Abrams
Wed, 05 Aug 1992 23:07
@DSUM works fine after all--I blew it
Author: Marshall Abrams
Date: Wed, 05 Aug 1992 23:07
Date: Wed, 05 Aug 1992 23:07
48 lines
2672 bytes
2672 bytes
I wrote: > I've tried all of the database functions except @DSTD and @DVAR, and > only @DCOUNT seems to work. (This counts the cells in the input_range > that meet the criteria in criteria_range.) @DCOUNT works fine, but > the other functions, including @DSUM, always return 0. > .... (long explanation of example using @DSUM and @DCOUNT) I can't believe I did this. @DSUM, etc. work perfectly. It's me that screwed up. I apologize for sending my mistake around the globe. I made a really stupid mistake. When I tested this at home, I had 3 columns in my database, rather than the single column in the example I gave in my posting. In the second argument to the @DCOUNT and @DSUM formulas, I referred to column 1 when I should have referred to column 2. i.e. in the spreadsheet at home, I had: @DCOUNT(A1..C19,1,G1..G2) @DSUM(A1..C19,1,G1..G2) when I should have had: @DCOUNT(A1..C19,2,G1..G2) @DSUM(A1..C19,2,G1..G2) Column 2 contained the numerical values to be summed, whereas column 1 contained only labels. @DCOUNT works no matter which column you give as the second argument; it's just counting records/rows--it doesn't have to do anything with the contents of any particular field/column. But @DSUM of course needs to sum a column containing numbers, and I hadn't given it that. Other database functions, such as @DAVG, also failed because of the same problem. I want to apologize not just for posting a problem based on a stupid mistake, but also for posting as my example something that I hadn't literally tried. I was so sure that the example in my posting was functionally identical to what I'd done at home. But it wasn't. If I'd actually tried the example I posted, perhaps I would have seen my mistake. (In the example I posted, there was only one column--kind of hard to get the column wrong when you've only got one column to choose from). I'm really embarrassed about posting the untested example. I should know better. Thanks much to the people who spent time reading and replying. Marshall Abrams ab2r@midway.uchicago.edu
Thread Navigation
This is a paginated view of messages in the thread with full content displayed inline.
Messages are displayed in chronological order, with the original post highlighted in green.
Use pagination controls to navigate through all messages in large threads.
Back to All Threads