I have a date column. I created Month-Year column in my report using the following expression, but I am not able to sort month-year wise.
=MonthName(Month(Fields!new_sitevisiteddateutc.Value))& "-"& Year(Fields!new_sitevisiteddateutc.Value)
I would like to have MAY-2009 JUNE-2009 JANUARY-2011 MARCH-2011, however I am getting JUNE-2009 MARCH-2011 MAY-2009 JANUARY-2011.
Can someone help me with this?
In the table properties you can add multiple sorting fields and thier order.
Sort by year first and then month.
=Year(Fields!new_sitevisiteddateutc.Value)
=Month(Fields!new_sitevisiteddateutc.Value)
Related
As a data analyst, I would like to see the report in a pivot table automatically for the current month, so that I can take a look at it and don't have to change the date filter manually.
This is the formula to show the first day of the current month. (Which is the criteria I need, first of the current month)
=EOMONTH(today(),-1)+1
It works when I put this formula in any cell.
But when I put it in the pivot "filter by condition" option it doesn't work.
This is what I tried.
Text is exactly =EOMONTH(today(),-1)+1 (In formula box)
The date is exactly =EOMONTH(today(),-1)+1 (In formula box)
Here a screenshot of the options
Any help will be greatly appreciated.
I've never had great luck with the pivot table filter criteria in Sheets, I typically filter the data first if it's more advanced or use aggregating functions. In the Sheets pivot tables are better for quick analysis than dashboards.
There's probably a few ways to do it, but one of the easier ways would be to duplicate the data tab, clear the data and use a filter function to retrieve data. Update the Pivot table data source to the new tab. This will always only be the current month's data.
Basically you filter the data before the pivot table, with the [filter function][1].
=Filter(data , [date col]>=EOMONTH(today(),-1)+1 , [date col]< date(year(today()), month(today())+1,1)
You can also add a month column to the data and then filter on that column, however each month you would need to update the month filter in the pivot table.
=date(year([date cell]),Month([date cell]),1)
If you're using it for a 'dashboard' of sorts, I would generally recommend to create it yourself with aggregating formulas (sumifs, countifs, ect) and then you can use the more complex filters.
try custom formula:
=MONTH(A2)=MONTH(TODAY())
where A2 is first cell of column containing valid dates
You can try to Filter by a Custom Formula:
=month(DatePurchase)=month(TODAY())
Where DatePurchase is the Field Name.
I have a table with members, date and results. The date represent the month for which all the results were generated for various members. Table stores results for multiple months. Now, i want to compare results of current month with last month for particular member and assign “equal” , “>” or “<” sign based on their values. How can i do that in tableau?
Any help is greatly appreciated!
Thank you.
You can use the lookup function. Assuming you have below data:
you can create a lookup function in tableau with below expression:
LOOKUP(sum([Result]),-1)
Note you need to use an aggregate function on your measure
After creating a lookup column create a calculated field to do data comparison:
This should give you the result you are looking for:
You can edit the table calculations to define the reset level for your calculation:
I'm trying to find a way to create a table like the one above, but instead of having columns of months I would like to have columns of MTD, QTD, YTD for all selected measure values. I created calculated fields on the [Date] field but when I try to use that it still splits the data in to separate columns of months and quarters... I'm using two data sources and they are linked on the [Date] field. If I try to put two of my calculated fields in the columns bar it just combines them like 'MTD/YTD'. How can I get them to display as separate columns?
I know this is strange because there will be overlapping data (everything in the MTD will also be in the QTD and the YTD).
I found a way to do this. I created a calculated field on the date field and assigned 'MTD' to all records from the last month. Then I assigned 'QTD' to all records from the start of the quarter to the day before the start date of the 'MTD' records. Then I assigned 'YTD' to all records from the start of the year to the day before the start of the 'QTD' records. (this way there are no overlapping records).
After that I just did a quick table calc to make each of them a 'running total' table (across).
I created parameters for the dates so the can easily be updated.
When I group according to date in Jasper, same date entries do not get grouped together.
For example, if I have 3 entries with the same date, two get grouped together, followed by a group of a another date, and then the one that was supposed to get grouped with the other two gets a whole new grouping of it's own later...
How do I get the same dates to all group together?
I'm using an oracle database.
To use grouping your data must be sorted firstly by the grouping field i.e. the field you want to group data by must be the first column in your ORDER BY clause as groups are created per occurence of the grouping field. So if the occurrences of the grouping field are not continous you will get multiple groups of the same grouping field.
I'm creating several pivot tables. I've got my data source with a date column (set as Date). When I add the date either as a filter or row/column I get a complete list of all dates instead of a nice tree view by Year / Month / Day.
Is anyone able to provide some assistance? I'm tearing my hair out!
I don't think you can group dates for a pivot table filter, you can only do it for a regular filter or for a row/column of a pivot table.
To do it, just add the date field to the row/column of the pivot table and on the table shown, right click on one of the dates and click 'group' or 'ungroup'.
Check this link for more details:
http://office.microsoft.com/en-001/excel-help/group-items-in-a-pivottable-report-HP010175903.aspx