Good day,
I have a table in SQL that I am reporting on. It contains a few different
fields. One of them is the running total for the month. What I need is a
report that shows both this running total field as well as each days value.
Each days values can be calculated by taking day 1's running total and minus
it from day 2's value to give day 1's day value. Therefore the last running
total value will not have a actual day value. Can anyone help me please, I am
battling and have been for quite some time.
Any help would be greatly apreciated.
ThanksIf you group by the day, you should be able to just bring in the sum for
that day & keep the running total separate.
If that doesn't work, you could use an IF statement in your sum to display
that days total.
EX:
= SUM(IIF(( CONDITION) , Fields!SalesAmount.Value , Nothing))
Where condition is a formula that looks for the current day.
Hope this helps,
MB
"PLSH" <PLSH@.discussions.microsoft.com> wrote in message
news:1695C145-4EAD-42F1-9C6C-AECC8C500C91@.microsoft.com...
> Good day,
> I have a table in SQL that I am reporting on. It contains a few different
> fields. One of them is the running total for the month. What I need is a
> report that shows both this running total field as well as each days
> value.
> Each days values can be calculated by taking day 1's running total and
> minus
> it from day 2's value to give day 1's day value. Therefore the last
> running
> total value will not have a actual day value. Can anyone help me please, I
> am
> battling and have been for quite some time.
> Any help would be greatly apreciated.
> Thanks|||Hi Mark,
Thanks for the help but I am still stumped. the report will show records for
a whole month for instance and each day has to calculate the cost for that
day from the running total. Can I still use your suggestion, can you possibly
elaborate?
Thanks
"Mark" wrote:
> If you group by the day, you should be able to just bring in the sum for
> that day & keep the running total separate.
> If that doesn't work, you could use an IF statement in your sum to display
> that days total.
> EX:
> = SUM(IIF(( CONDITION) , Fields!SalesAmount.Value , Nothing))
> Where condition is a formula that looks for the current day.
> Hope this helps,
> MB
> "PLSH" <PLSH@.discussions.microsoft.com> wrote in message
> news:1695C145-4EAD-42F1-9C6C-AECC8C500C91@.microsoft.com...
> > Good day,
> >
> > I have a table in SQL that I am reporting on. It contains a few different
> > fields. One of them is the running total for the month. What I need is a
> > report that shows both this running total field as well as each days
> > value.
> > Each days values can be calculated by taking day 1's running total and
> > minus
> > it from day 2's value to give day 1's day value. Therefore the last
> > running
> > total value will not have a actual day value. Can anyone help me please, I
> > am
> > battling and have been for quite some time.
> >
> > Any help would be greatly apreciated.
> >
> > Thanks
>
>|||Hi Mark again,
Not to worry managed to sort it out. Found the previous function and works
like a charm, never thought it would be such an easy command, was expecting
something much more complex.
Thanks
"PLSH" wrote:
> Hi Mark,
> Thanks for the help but I am still stumped. the report will show records for
> a whole month for instance and each day has to calculate the cost for that
> day from the running total. Can I still use your suggestion, can you possibly
> elaborate?
> Thanks
> "Mark" wrote:
> > If you group by the day, you should be able to just bring in the sum for
> > that day & keep the running total separate.
> > If that doesn't work, you could use an IF statement in your sum to display
> > that days total.
> > EX:
> > = SUM(IIF(( CONDITION) , Fields!SalesAmount.Value , Nothing))
> > Where condition is a formula that looks for the current day.
> > Hope this helps,
> > MB
> >
> > "PLSH" <PLSH@.discussions.microsoft.com> wrote in message
> > news:1695C145-4EAD-42F1-9C6C-AECC8C500C91@.microsoft.com...
> > > Good day,
> > >
> > > I have a table in SQL that I am reporting on. It contains a few different
> > > fields. One of them is the running total for the month. What I need is a
> > > report that shows both this running total field as well as each days
> > > value.
> > > Each days values can be calculated by taking day 1's running total and
> > > minus
> > > it from day 2's value to give day 1's day value. Therefore the last
> > > running
> > > total value will not have a actual day value. Can anyone help me please, I
> > > am
> > > battling and have been for quite some time.
> > >
> > > Any help would be greatly apreciated.
> > >
> > > Thanks
> >
> >
> >sql
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment