The original solution works great!!!!!!
I've been working with SqlServer since the Sybase days, in .Net since it came out and I really think SSRS has many glaring weaknesses. This being one of them. I simply want to write a report against a cube, often those reports involve date ranges. In fact I would say most of my reports involve a date range. And to jump through this many hoops just to get my date ranges into the MDX is plain silly. And my users don't want to pick a begin and end date by navigating through a hierarchy of year, quarter, month and day, they want a date picker (calendar) option. Always have and they always will. That is like entering a zip code by navigating through state and city first.
Anyway, it is important to note that to do this you must:
a) Select the elipsis (...) button next to your main data set.
b) Press the "f(x)" button on the dialog box (Query Tab, Query String area)
c) place the entire query string in double quotes and put an equal sign at the front of it (from Select <statement> to ="Select <statement>"
I found it easiest to build the query string normally. Add a filter (non-parameter) with a date range (or single date if you are using a single date) that will act as place holders in your query string for the places you need to add the dat functionality. Just for examples I have:
="SELECT NON EMPTY { [Measures].[Ticket Revenue], [Measures].[Tickets Sold] } ON COLUMNS, NON EMPTY { ([dTheatre].[Dim Theatre].[Dim Theatre].ALLMEMBERS * [dFilm].[Dim Film].[Dim Film].ALLMEMBERS ) } DIMENSION PROPERTIES MEMBER_CAPTION, MEMBER_UNIQUE_NAME ON ROWS FROM ( SELECT ( [dDate].[Date Value].&[" + CStr(Year(Parameters!BeginDate.Value)) + "-" + Right("0" + Cstr(Month(Parameters!BeginDate.Value)), 2) + "-"+ Right("0" + Cstr(Day(Parameters!BeginDate.Value)), 2) + "T00:00:00] : [dDate].[Date Value].&["+ CStr(Year(Parameters!EndDate.Value)) + "-" + Right("0" + Cstr(Month(Parameters!EndDate.Value)), 2) + "-"+ Right("0" + Cstr(Day(Parameters!EndDate.Value)), 2) +"T00:00:00] ) ON COLUMNS FROM [FilmSales]) CELL PROPERTIES VALUE, BACK_COLOR, FORE_COLOR, FORMATTED_VALUE, FORMAT_STRING, FONT_NAME, FONT_SIZE, FONT_FLAGS"
The Month and day must be padded to ensure they are two characters. By taking the Right 2 of the value prepended with a 0 makes 10 become 10 and 5 become 05.