title: SUM of a YTD-value by Year for several selected years
body: <p>I am trying to put together an SQL statement that returns the SUM of a value by Year for several selected years, but on a year to date basis. In other words, running the report by selecting years I need the value for the selected years on a year to date basis. This could be something like this: By selecting the years 2015, 2014 until 2010 the Report should give 2015 value ytd of 25.02.2015, 2014 ytd of 25.02.2014 and so on.</p>
  
  <p>Yet I only figured out how to select the Dates for each year to date value manually., but clearly the I was thinking. However, I was hoping to have some of this work handled with my SQL Statement using the selected years Parameter and add month and day somehow.</p>
  
  <p>Has anyone ever tackled this type of problem with an SQL statement, and if so, what is the trick that I am missing?</p>
  
  <p>My current sql statement for ytd data is similar to the following:
  SELECT NON EMPTY { [Measures].[Sales Turnover YTD], [Measures].[Order Intake YTD] } ON COLUMNS FROM ( SELECT ( STRTOSET(@DateDate, CONSTRAINED)</p>
  
  <p>This works perfectly for the one year, but still I am seeking the solution for several years.</p>
  
  <p>As described above my desired result would be: after choosing several fiscal years (e.g. 2010-2015) I will get following values:
  2015 Sales Turnover YTD Order Intake YTD on date today
  2014 Sales Turnover YTD Order Intake YTD on date today one year ago 
  and so on.. </p>