Wednesday, March 7, 2012

reportingsvcs 2000 grouping by week

Hi, I have a yearly report that needs to be group by week. How I make
the report group my data by week? At this time I have it running with
@.startdate and @.enddate, but the big boss needs the report group by
week. All help and advice will be a great help.
Thanks
abzOn Jul 11, 6:01 pm, abz <abz81s...@.gmail.com> wrote:
> Hi, I have a yearly report that needs to be group by week. How I make
> the report group my data by week? At this time I have it running with
> @.startdate and @.enddate, but the big boss needs the report group by
> week. All help and advice will be a great help.
> Thanks
> abz
Right-click the table/matrix control and select Properties. Select the
Groups tab and select the Add.../Edit... button. Below Group on: ->
Expression enter an expression similar to the following:
=Datepart("ww", Fields!SomeFieldName.Value)
Regards,
Enrique Martinez
Sr. Software Consultant|||On Jul 11, 6:19 pm, EMartinez <emartinez...@.gmail.com> wrote:
> On Jul 11, 6:01 pm, abz <abz81s...@.gmail.com> wrote:
> > Hi, I have a yearly report that needs to be group by week. How I make
> > the report group my data by week? At this time I have it running with
> > @.startdate and @.enddate, but the big boss needs the report group by
> > week. All help and advice will be a great help.
> > Thanks
> > abz
> Right-click the table/matrix control and select Properties. Select the
> Groups tab and select the Add.../Edit... button. Below Group on: ->
> Expression enter an expression similar to the following:
> =Datepart("ww", Fields!SomeFieldName.Value)
> Regards,
> Enrique Martinez
> Sr. Software Consultant
Thank you very much Enrique, it grouped it by week, but the date it
show jumps around. Meaning, it dont displays every friday as the
display date, it shows monday as the date for one week, the week after
is friday. How do I make it display every friday?
=DatePart("ww", Fields!DESIRED_WANT_DATE.Value)
I read some where about putting +5, or an actual day of week (friday).
Would that apply to this?
Thanks again,
abz|||On Jul 13, 12:37 pm, abz <abz81s...@.gmail.com> wrote:
> On Jul 11, 6:19 pm, EMartinez <emartinez...@.gmail.com> wrote:
>
> > On Jul 11, 6:01 pm, abz <abz81s...@.gmail.com> wrote:
> > > Hi, I have a yearly report that needs to be group by week. How I make
> > > the report group my data by week? At this time I have it running with
> > > @.startdate and @.enddate, but the big boss needs the report group by
> > > week. All help and advice will be a great help.
> > > Thanks
> > > abz
> > Right-click the table/matrix control and select Properties. Select the
> > Groups tab and select the Add.../Edit... button. Below Group on: ->
> > Expression enter an expression similar to the following:
> > =Datepart("ww", Fields!SomeFieldName.Value)
> > Regards,
> > Enrique Martinez
> > Sr. Software Consultant
> Thank you very much Enrique, it grouped it by week, but the date it
> show jumps around. Meaning, it dont displays every friday as the
> display date, it shows monday as the date for one week, the week after
> is friday. How do I make it display every friday?
> =DatePart("ww", Fields!DESIRED_WANT_DATE.Value)
> I read some where about putting +5, or an actual day of week (friday).
> Would that apply to this?
> Thanks again,
> abz
You're welcome. Yes, that should apply to this scenario.
Regards,
Enrique Martinez
Sr. Software Consultant|||mmm...well for some reason its not working. Is it because the way
that is written?
=(DatePart("ww", Fields!DESIRED_WANT_DATE.Value)+6)
Also, is it because the Fields!DESIRED_WANT_DATE.Value is an actual
field that already has dates filled in Visual'
well, thanks once again for your help
Abz|||On Jul 16, 11:08 am, abz <abz81s...@.gmail.com> wrote:
> mmm...well for some reason its not working. Is it because the way
> that is written?
> =(DatePart("ww", Fields!DESIRED_WANT_DATE.Value)+6)
> Also, is it because the Fields!DESIRED_WANT_DATE.Value is an actual
> field that already has dates filled in Visual'
> well, thanks once again for your help
> Abz
You might want to use something like:
=DatePart("ww", Dateadd("d", 6, Fields!DESIRED_WANT_DATE.Value))
Hope this helps.
Regards,
Enrique Martinez
Sr. Software Consultant|||On Jul 16, 4:27 pm, EMartinez <emartinez...@.gmail.com> wrote:
> On Jul 16, 11:08 am, abz <abz81s...@.gmail.com> wrote:
> > mmm...well for some reason its not working. Is it because the way
> > that is written?
> > =(DatePart("ww", Fields!DESIRED_WANT_DATE.Value)+6)
> > Also, is it because the Fields!DESIRED_WANT_DATE.Value is an actual
> > field that already has dates filled in Visual'
> > well, thanks once again for your help
> > Abz
> You might want to use something like:
> =DatePart("ww", Dateadd("d", 6, Fields!DESIRED_WANT_DATE.Value))
> Hope this helps.
> Regards,
> Enrique Martinez
> Sr. Software Consultant
This is very weird.....the expression worked for a different report
I tried it on, but the one I really need it on still dont take. I dont
know what's wrong with it, but Enrique, thank you very much with the
grouping.
Now, dont want to be a pain, but I know to get current date is
GETDATE(), but if I want a report to be just for the current month,
what would the expression be? I tried =DatePart("m",
SHIPPER.SHIPPED_DATE) also =DATEADD(month, shipper.shipped_date) and
that dont work...I also tried GETMONTH() but I found out that dont
exist...well, if its possible your help is very greatful...
once again...Thank You very much
Abner|||On Jul 18, 11:27 am, abz <abz81s...@.gmail.com> wrote:
> On Jul 16, 4:27 pm, EMartinez <emartinez...@.gmail.com> wrote:
>
> > On Jul 16, 11:08 am, abz <abz81s...@.gmail.com> wrote:
> > > mmm...well for some reason its not working. Is it because the way
> > > that is written?
> > > =(DatePart("ww", Fields!DESIRED_WANT_DATE.Value)+6)
> > > Also, is it because the Fields!DESIRED_WANT_DATE.Value is an actual
> > > field that already has dates filled in Visual'
> > > well, thanks once again for your help
> > > Abz
> > You might want to use something like:
> > =DatePart("ww", Dateadd("d", 6, Fields!DESIRED_WANT_DATE.Value))
> > Hope this helps.
> > Regards,
> > Enrique Martinez
> > Sr. Software Consultant
> This is very weird.....the expression worked for a different report
> I tried it on, but the one I really need it on still dont take. I dont
> know what's wrong with it, but Enrique, thank you very much with the
> grouping.
> Now, dont want to be a pain, but I know to get current date is
> GETDATE(), but if I want a report to be just for the current month,
> what would the expression be? I tried =DatePart("m",
> SHIPPER.SHIPPED_DATE) also =DATEADD(month, shipper.shipped_date) and
> that dont work...I also tried GETMONTH() but I found out that dont
> exist...well, if its possible your help is very greatful...
> once again...Thank You very much
> Abner
You are correct for the report expression: to get the month. The
format is:
=DatePart("m", Now())
-or- you could use
=DatePart("m", Fields!SHIPPED_DATE.Value)
Of course, in SQL it would be:
datepart(mm, getdate())
Hope this helps.
Regards,
Enrique Martinez
Sr. Software Consultant

No comments:

Post a Comment