Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
dan dan is offline
external usenet poster
 
Posts: 866
Default Excel 2007: =DSUM not working as expected

I have a reporting spreadsheet with two workbooks.
Workbook 'Data' contains rows of data, lots of columns but two that are
relevant: 'JulianDay' and 'Transactions'. The First Few rows a

JulianDay Transactions
001 140
002 1298
003 166
....
031 197
032 151
....
etc.

In Workbook 'Report', I am attempting to sum the number of transactions for
January - i.e. JulianDay = 001 and JulianDay <=031.

I do this for each month - i.e. 12 DSUM formulas. In EVERY formula, DSUM
excludes the first day of the month. I am stumpted as to why.

The DSUM formula is: =DSUM(Data!$A$1:$Y$369,C$4,CriteriaJan)
whe
Data!$A$1:$Y$369 is the data range;
C$4 contains the text value "Transactions", and
CriteriaJan is a range that looks like this:
JulianDay JulianDay
='001' <='031'


I have built the criteria (e.g. ='001' or <='031') with a text formula that
works for every JulianDay except the first day of the month.

An example of the text formula that builds the criteria looks like this:
="='" &TEXT(K5,0)&"'", where
K5, in this case, contains the numeric value 244 (The Julian Day for Sept 1)

Can anyone offer any suggestions on what I am doing wrong or does anyone see
anything silly I have overlooked?

  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 3,718
Default Excel 2007: =DSUM not working as expected

Assume the Julian days are numeric values not text values.

=SUMPRODUCT(--(MONTH(DATE(YEAR(TODAY()),1,$A$1:$A$40))=ROWS($1:1 )),$B$1:$B$40)

adjust your range to suit

copy down to the next 11 rows



"Dan" wrote:

I have a reporting spreadsheet with two workbooks.
Workbook 'Data' contains rows of data, lots of columns but two that are
relevant: 'JulianDay' and 'Transactions'. The First Few rows a

JulianDay Transactions
001 140
002 1298
003 166
...
031 197
032 151
...
etc.

In Workbook 'Report', I am attempting to sum the number of transactions for
January - i.e. JulianDay = 001 and JulianDay <=031.

I do this for each month - i.e. 12 DSUM formulas. In EVERY formula, DSUM
excludes the first day of the month. I am stumpted as to why.

The DSUM formula is: =DSUM(Data!$A$1:$Y$369,C$4,CriteriaJan)
whe
Data!$A$1:$Y$369 is the data range;
C$4 contains the text value "Transactions", and
CriteriaJan is a range that looks like this:
JulianDay JulianDay
='001' <='031'


I have built the criteria (e.g. ='001' or <='031') with a text formula that
works for every JulianDay except the first day of the month.

An example of the text formula that builds the criteria looks like this:
="='" &TEXT(K5,0)&"'", where
K5, in this case, contains the numeric value 244 (The Julian Day for Sept 1)

Can anyone offer any suggestions on what I am doing wrong or does anyone see
anything silly I have overlooked?

  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
dan dan is offline
external usenet poster
 
Posts: 866
Default Excel 2007: =DSUM not working as expected

The JulianDays column is text, exactly three characters, left-zero filled
(i.e. '001' or '031') and comes from an external data source.

Does anyone know if the criteria "=" (Greater than or equal to) or "<="
are valid? All of the Microsoft examples I have found only use "<" or "".
I have yet to see an example that adds "or equal to" to the criteria. (It
looks like both DSUM and SUMIF use the same syntax for criteria.)

"Teethless mama" wrote:

Assume the Julian days are numeric values not text values.

=SUMPRODUCT(--(MONTH(DATE(YEAR(TODAY()),1,$A$1:$A$40))=ROWS($1:1 )),$B$1:$B$40)

adjust your range to suit

copy down to the next 11 rows



"Dan" wrote:

I have a reporting spreadsheet with two workbooks.
Workbook 'Data' contains rows of data, lots of columns but two that are
relevant: 'JulianDay' and 'Transactions'. The First Few rows a

JulianDay Transactions
001 140
002 1298
003 166
...
031 197
032 151
...
etc.

In Workbook 'Report', I am attempting to sum the number of transactions for
January - i.e. JulianDay = 001 and JulianDay <=031.

I do this for each month - i.e. 12 DSUM formulas. In EVERY formula, DSUM
excludes the first day of the month. I am stumpted as to why.

The DSUM formula is: =DSUM(Data!$A$1:$Y$369,C$4,CriteriaJan)
whe
Data!$A$1:$Y$369 is the data range;
C$4 contains the text value "Transactions", and
CriteriaJan is a range that looks like this:
JulianDay JulianDay
='001' <='031'


I have built the criteria (e.g. ='001' or <='031') with a text formula that
works for every JulianDay except the first day of the month.

An example of the text formula that builds the criteria looks like this:
="='" &TEXT(K5,0)&"'", where
K5, in this case, contains the numeric value 244 (The Julian Day for Sept 1)

Can anyone offer any suggestions on what I am doing wrong or does anyone see
anything silly I have overlooked?

  #4   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 3,718
Default Excel 2007: =DSUM not working as expected

My formula does works on text value


"Dan" wrote:

The JulianDays column is text, exactly three characters, left-zero filled
(i.e. '001' or '031') and comes from an external data source.

Does anyone know if the criteria "=" (Greater than or equal to) or "<="
are valid? All of the Microsoft examples I have found only use "<" or "".
I have yet to see an example that adds "or equal to" to the criteria. (It
looks like both DSUM and SUMIF use the same syntax for criteria.)

"Teethless mama" wrote:

Assume the Julian days are numeric values not text values.

=SUMPRODUCT(--(MONTH(DATE(YEAR(TODAY()),1,$A$1:$A$40))=ROWS($1:1 )),$B$1:$B$40)

adjust your range to suit

copy down to the next 11 rows



"Dan" wrote:

I have a reporting spreadsheet with two workbooks.
Workbook 'Data' contains rows of data, lots of columns but two that are
relevant: 'JulianDay' and 'Transactions'. The First Few rows a

JulianDay Transactions
001 140
002 1298
003 166
...
031 197
032 151
...
etc.

In Workbook 'Report', I am attempting to sum the number of transactions for
January - i.e. JulianDay = 001 and JulianDay <=031.

I do this for each month - i.e. 12 DSUM formulas. In EVERY formula, DSUM
excludes the first day of the month. I am stumpted as to why.

The DSUM formula is: =DSUM(Data!$A$1:$Y$369,C$4,CriteriaJan)
whe
Data!$A$1:$Y$369 is the data range;
C$4 contains the text value "Transactions", and
CriteriaJan is a range that looks like this:
JulianDay JulianDay
='001' <='031'

I have built the criteria (e.g. ='001' or <='031') with a text formula that
works for every JulianDay except the first day of the month.

An example of the text formula that builds the criteria looks like this:
="='" &TEXT(K5,0)&"'", where
K5, in this case, contains the numeric value 244 (The Julian Day for Sept 1)

Can anyone offer any suggestions on what I am doing wrong or does anyone see
anything silly I have overlooked?

  #5   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 1,766
Default Excel 2007: =DSUM not working as expected

Hi,

Your best option would be to convert the Julian dates to numeric values and
then use the criteria as =1 and <=9

--
Regards,

Ashish Mathur
Microsoft Excel MVP
www.ashishmathur.com

"Dan" wrote in message
...
I have a reporting spreadsheet with two workbooks.
Workbook 'Data' contains rows of data, lots of columns but two that are
relevant: 'JulianDay' and 'Transactions'. The First Few rows a

JulianDay Transactions
001 140
002 1298
003 166
...
031 197
032 151
...
etc.

In Workbook 'Report', I am attempting to sum the number of transactions
for
January - i.e. JulianDay = 001 and JulianDay <=031.

I do this for each month - i.e. 12 DSUM formulas. In EVERY formula, DSUM
excludes the first day of the month. I am stumpted as to why.

The DSUM formula is: =DSUM(Data!$A$1:$Y$369,C$4,CriteriaJan)
whe
Data!$A$1:$Y$369 is the data range;
C$4 contains the text value "Transactions", and
CriteriaJan is a range that looks like this:
JulianDay JulianDay
='001' <='031'


I have built the criteria (e.g. ='001' or <='031') with a text formula
that
works for every JulianDay except the first day of the month.

An example of the text formula that builds the criteria looks like this:
="='" &TEXT(K5,0)&"'", where
K5, in this case, contains the numeric value 244 (The Julian Day for Sept
1)

Can anyone offer any suggestions on what I am doing wrong or does anyone
see
anything silly I have overlooked?



Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Value function not working as expected in Excel 2007 bdevier Excel Worksheet Functions 1 November 28th 08 05:24 PM
Old DSUM formula not working in Excel 2007 Hansard Excel Worksheet Functions 0 June 27th 08 03:23 AM
Help !!! My code is not working as expected. Ayo Excel Discussion (Misc queries) 3 August 30th 07 10:39 PM
=NETWORKDAYS not working as expected and as it once did USAOz Excel Worksheet Functions 2 July 13th 06 03:02 PM
Lookup Not working as expected trumpy81 New Users to Excel 5 June 30th 05 07:41 PM


All times are GMT +1. The time now is 10:04 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"