Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
How to sort year asc and month as Jul=1,Aug=2, as so on?
I have concate year and month in and set at variable.
But, I need the Year as asc
like
2013,2014
and month as JUL at first, Aug as second, and so on
like:
Jul 2013, Aug 2013,........Jun 2013,July 2014, Aug 2014,....Jun 2014
[note: Jul and 2013 are different field but concate in variable "vMonthYr"
Hi,
Create a inline Table as
Load * inline [
Month,SortOrder
Jan,7
Feb,8
Mar,9
Apr,10
May,11
Jun,12
Jul,1
Aug,2
Sep,3
Oct,4
Nov,5
Dec6
];
Make sure that This table is linked with the Month Field of your master Calendar.
Now you can use the SortOrder field in Sorting Tab ->Expression.
Regards,
Kaushik Solanki
load
Year,
month,
Date#(Year & ' ' & month ,'MMM YYYY') as Year_month
Resident TABLE ORDER BY Year asc;
Hi,
Please find the attached file to rearrange months as per your requirment.
Niranjan M.
IN PIVOTE-
dimension--
Expression--> in sort tab--> check the expression then inside it write this code
IF(DATE(Month & ' ' & Year,'MMM YYYY')='Jul 2013',1,
IF(DATE(Month & ' ' & Year,'MMM YYYY')='Aug 2013',2,
IF(DATE(Month & ' ' & Year,'MMM YYYY')='Sep 2013',3,
IF(DATE(Month & ' ' & Year,'MMM YYYY')='Oct 2013',4,
IF(DATE(Month & ' ' & Year,'MMM YYYY')='Nov 2013',5,
IF(DATE(Month & ' ' & Year,'MMM YYYY')='Dec 2013',6,
IF(DATE(Month & ' ' & Year,'MMM YYYY')='Jan 2013',7,
IF(DATE(Month & ' ' & Year,'MMM YYYY')='Feb 2013',8,
IF(DATE(Month & ' ' & Year,'MMM YYYY')='Mar 2013',9,
IF(DATE(Month & ' ' & Year,'MMM YYYY')='Apr 2013',10,
IF(DATE(Month & ' ' & Year,'MMM YYYY')='May 2013',11
IF(DATE(Month & ' ' & Year,'MMM YYYY')='Jun 2013',12)
Thanks for your reply.
My month is sort out but now its year problem
like I have report:
Jul 2012,Jul 2013, Jul 2014,Aug 2012, Aug 2013, Aug 2014
like this...but I want :
Jul 2012,Aug 2012.....,Jul 2013, Aug 2013,....., Jul 2014, Aug 2014.....
as I told before that Month and year are 2 different fields , I concatenated it.