Exit
  • Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
  • 한국 커뮤니티
0

grouping by date

Explorer ,
Jul 28, 2008 Jul 28, 2008
Hello All
Im just about to start a new project and was woundering if any one had any pointers on how I can group by weeks when selecting data

Each line of data consists of a part number and a due date for example.
I wish to select data and group by weeks 21 / July - 27 / July etc

So all parts with a due date between week start and week end dates would get grouped up.

Question can you group on the TSQL statment by ISO weeks etc or will this have to be done in the CFM code?

Not asking for a solution here im very willing to sit and think for myself, just wondered on any pointers that might be around.

Kind Regards Guy
TOPICS
Advanced techniques
286
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Explorer ,
Jul 28, 2008 Jul 28, 2008
Hello All,

Well that was easy to work out :). Can do it in the TSQL, code below just in case any one was interested.

select month(planddate) AS plandate, planpart
, sum(planoq) AS planoq
from planned
group
by month(planddate), planpart

Kind Regards Guy
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Beginner ,
Jul 28, 2008 Jul 28, 2008
LATEST
Thanks Hagster.
For music visit http://mp3katalog.eu
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Resources