SSRS BIDS 2008 Parameter Date Range - sql-server

I have produced a report where the user will need to view financial years data.
So for example April 2010 - March 2011 will have one years data however if the user selects this as in my image, data for January, February, March in 2010 will be brought as well as January, Febrary and March 2011, when I dont want the Jan,Feb,Mar for 2010 as the financial year begins in April.
I therfore need to be able select a data range using parameters to stop bringing data through that I didnt ask for.
Can anyone advise me how to do this?

You can build a month-year key to use instead of your ad-hoc year and month parameters. You can then display it for example as YYYY/MM - so that you can select 2010/04 through 2011/03.
Another option would be to have from month (with year) to month (with year).
Yet another option would be to have a year, month, and number-of-months, selecting 2010, 04, then 12 for number-of-months.
Your two parameters aren't aware of eachother in the way that you want it to be.

Related

SSRS - Add year to month

In my report, i show the sales commission for 3 months from each sales person. I've also added the payout month. For a better overall look, i want to add the year to the payout month.
This is the month in my SQL-Query :
,[Monat] = convert(varchar(4),Year(Datum)) + right('00' + convert(varchar(2),Month(Datum)),2)
Right now, the expression for my payout month is this:
=MONTHNAME(IIF(RIGHT(Fields!Monat.Value,2)+2>=13,RIGHT(Fields!Monat.Value,2)-12+2,RIGHT(Fields!Monat.Value,2)+2))
The payout is always two months in the future. Commission of december 2020 will be payed in february 2021, january 2021 will be payed in march 2021 and so on.
I want the result to look like this:
Februar 2021,
März 2021
etc.
Is there a way to depict that in the SSRS expression? Thanks in advance.
If you just need to display the month and year from a date field after you have added 2 months to it, then you can just do something like this.
=DATEADD(DateInterval.Month, 2, Fields!Datum.Value)
You can then format the textbox using MMMM yyyy to display it as you want.
Alternatively, you can do it all in a single step but this should be avoided if possible as you are then losing the date and converting to a string. If you exported to excel for example, you would not be able to do anything with the cell as it would just be a string.
If you really have to do this in all in a single expression then you can use
=FORMAT(DATEADD(DateInterval.Month, 2, Fields!Datum.Value), "MMMM yyyy")

Dynamically filter the date by 6 months from today

I basically want to be able to dynamically filter out my chart to display data for the last 6 months. For example, it would show Jan 2019 to June 2019 and in July it would show between Feb 2019 to July 2019
Presently, I'm using filters. I was thinking of creating a calculated field for the 6 months but there are no functions to help me play with dates.
In the date-picker options, choose the one at the very bottom of the list which is called Advanced. Click on the end date option and where it says 'fixed' click and choose today. Do the same for the start date and you get the option to enter your conditions, which in this case would be today minus 6 months

Update data entry for one month and future months

I think it is a straightforward question that requires some macro modification in my file, I will appreciate your help.
I am using this very useful form for data entry (Data Entry Form (Add/View)): http://www.contextures.com/xlForm02.html
I've adjusted it for my purpose (to track staff movements, changes and new starters), see the file here: http://www.filedropper.com/formsheeteditopttest2-creatingonemastersheetv8forstackoverflow
Every worker has a unique ID and a row per month. In the future the manager of these employees will be able to update the sheet (Input) to reflect any changes that are happening to the person (e.g. promotions, changes of site, change to the role name etc.).
So the two scenarios I am trying to do are for A - update to the current worker, B - adding a new starter.
A - when your UPDATE e.g. job level for one person in e.g. March 2017, this change should be reflected for this person for the rest of the year so for April 2017, May 2017 up to December 2017 etc.
B - When you ADD a new starter (e.g in May, 2017), I would like this starter to be added for each month i.e. May, 2017; June, 2017; July, 2017 up to December 2017 as well.
Any idea what to do to the existing macro code in the file for it to work?
Thanks
Ewa

qlikview table filter forcing wrong filter

Using qlikview 8 personnel edition.
On my main tab i have a chart that concats year and period (year and month) from this I use it as a filter to select periods, this works fine except when trying to select multiple years and periods, it allows selection but say:
Select all from year 2013, and up to year 2014 month 09. It actually selects all from 2013 and 2014.
why would it be doing this?
Some details:
=Num#(If(Len(Year & Period)=5,Year & '0' & Period, Year & Period))
outputs "201301" etc
Like I said i can select whatever month upto a month i want withing a year. However doing the same over multiple years forces it to select all months.
Because the year & month columns are separate in your model, making the selection that you described actually DID select all of the months. You got them from 2013. It didn't care that you only hoped to limit to 1-9 for 2014.
If possible, move that concatenation to the load script where it can become its own field and then you should be good to go.

Transposed day and month values in MS Access 2007 when using Update Query in SQL View

I have a challenge saving the date to an MS Access 2007 database especially for dates with the day less than the 12th of a month (i.e. the day between 01 to 11) If for example a February date - 07/02/2013 (dd/MM/yyyy) will be saved as 02/07/2013 in the database. While a similar February date 14/02/2013 will also be saved 14/02/2013. Retrieving the two dates: The first date will brought out as 2nd July and the second date will be 14th February.
Notice that the day and month values is transposed for dates less than the 11th. This happens when I use an update query (either from VB 2005 or directly within MS Access using SQL pane). I have set both the system short date settings (in Windows 7 OS) and the Date Format at field level (in the MS Access Table) to dd/MM/yyyy.
try - DateValue("dd-mm-yyyy")
or - Format(Date,"dd-mm-yyyy") as an expression builder.

Resources