1

I am from Europe. First day of the week Monday

Тhis is my code:

set datefirst 1;

select DATEPART(wk, did_dat) as Data, sum(sum_cre) as Suma 
from view_didknobj1 
where sas_kod between '505' and '505'  
  and did_dat between '2019.12.23' and '2019.12.29' 
group by DATEPART(wk, did_dat) 
order by DATEPART(wk, did_dat) asc

This data is returned from this query:

enter image description here

it should be like that: 52: 23669.77

marc_s
  • 732,580
  • 175
  • 1,330
  • 1,459
Вадим
  • 21
  • 1
  • 7

1 Answers1

0
SET DATEFIRST 1; 

Execute above sql command