SSRS Format Date Long Date without Zeros - date

we have an element on the report that appears as such
Print Values by: Thursday, July 01, 2021
The code we have it appears in our SSRS file as such
="Print Values by: " & FormatDateTime(Parameters!printBy_deadline.Value, DateFormat.LongDate)
We can't separate it out from the string. The users want it to appear exactly the same
Print Values by: Thursday, July 1, 2021 without the zero but the rest should remain the same. I've reviewed the other formats but they don't appear to do this.
Thank you.

You can use the FORMAT function to do custom formatting of dates and numbers rather than using the limited number of formats with FormatDateTime.
="Print Values by: " & FORMAT(Parameters!printBy_deadline.Value, "dddd, MMMM d, yyyy")
The result for TODAY is:
Friday, April 30, 2021
The d is for day. When there's 2 d's, the day of the month will always have a leading 0. If it's one d, it will have one or two digits. Three d's will show the day as the day name abbreviated while 4 d's will show the full day name.
The name logic is similar for M for the months.

Related

In Which format the date is given?

I have downloaded a dataset called Real estate valuation data set from https://archive.ics.uci.edu/ml/datasets/Real+estate+valuation+data+set?source=post_page . But I am not able to understand in which format the transaction date is given. They have given some examples like 2013.250=2013 March, 2013.500=2013 June, etc.
I encountered this same problem and I figured that the months were represented as a fraction of a year. So, for instance, June is the 6th month of the year, hence it is 6/12 = 0.5; that's why we had June 2013 as 2013.500, etc.

PowerBI Matrix with Year and Month

In the matrix below I have data from Jan 2020-Jan 2021, where the Jan column has the data from both 2021 and 2021. Is there any way to have the matrix add another column for Jan 2021 instead of aggregating that in with the Jan 2020 data?
Chose Year and Month in the date hierarchy column and then in the matrix click "expand all down one level in the hierarchy.
I am new to Power BI and I was wondering recently myself about something similar.
You can create a new column (text format) and combine month and year.
Date
Date Modified
dd-MM-yyyy
yyyy-MM
or
Date
Date Modified
dd-MM-yyyy
yyyy-MM (MMMM)
or
Date
Date Modified
dd-MM-yyyy
yyyy-MM (MMM)
It is not the most elegant solution, it changes a bit what is displayed (not simply months in the headers), it has a few disadvantages but it works.
I would be curious myself whether a better solution exists.
If you click on the date column you are using [InvoiceDate] and select the date option, it will separate out the two date values.
currently it is in a hierarchy showing just the month values but not the actual date
i have this but mine stays summed up at the year level even though the 'month' is expanded under the TimeByDay...
If I take out the year it will provide it like above but combines both... or as is it puts columns in the year

Is there a way to format and sort dates in a drop-down list on Google Sheets?

I have made a monthly budget sheet for someone who is not too confident using Google Sheets (or Excel) so I need it to be really simple.
https://docs.google.com/spreadsheets/d/10E9jX1Qlq-KQLCHupci3_8MiP7p5l-f2J1M5yFtfjQ0/edit?usp=sharing
In the monthly report, it is possible to select a month in cell B1 to fetch the relevant amounts using sumproduct/hlookup formulas.
Now that person should write "April 2019" or "May 2019" etc.
I would like to insert a dropdown list so there is no format issue whatsoever and for the items to be shown this way:
April 2019
May 2019
June 2019
...
with something like 24 months available.
I made a dropdown list from a formatted cell range but the dates display as "01-04-2019, 01-05-2019, etc" so it is not visually easy without an "mmmm aaa" format
AND
are not sorted chronologically (although my cell range is, but they rearrange themselves after 1 selection)
Going further, the dropdown would ideally have:
months in the format "mmmm yyyy"
sorted chronologically
dynamic list (12 months history, no future months)
this will give you dynamic dates in the range of (today's month +1) 2018 until (today's month +1) 2019
=ARRAYFORMULA(UNIQUE(TEXT(TO_DATE(ROW(
INDIRECT("A"&EOMONTH(DATE(YEAR(TODAY())-1, MONTH(TODAY())+1, 1), -1)+1):
INDIRECT("A"&EOMONTH(DATE(YEAR(TODAY()), MONTH(TODAY())+1, 1), 0)))),
"mmmm yyyy")))

Display a date in Google Sheets that increments by two weeks every other week

I would like a spreadsheet row to contain the date of today, but only on every other Thursday, changing at 9:30 am.
To give you an example:
Next thursday the 21.07.16 it shell contain "21.07.16".
Until in exactly 14 days on thursday the 4.08.16 it shell contain this date and than change to 4.08.16.
Also I would like this change to happen at 9:30 am.
I can not think of a way how to do this. Can you point me into a direction?
One has to set a starting datetime somewhere in the past, such as July 7, 2016, at 9:30am.
Then find the difference between the current and the starting datetime. Truncate this difference down to a multiple of 14, and add this value to the starting datetime.
The datetimes are represented in Sheets numerically as the number of days since December 30, 1899. In this system, 2016-07-07 9:30 is about 42558.4 So the formula would be
=42558.4 + 14*floor((now()-42558.4)/14)
The output should be formatted as a date.
A less cryptic version is
=value("2016-07-07 09:30") + 14*floor((now() - value("2016-07-07 09:30"))/14)
(value follows the local convention for parsing dates, but I hope the format I used will be understood universally.)

Converting month to date format in access

I have an access column which has values like May, May-June, November, January-February etc.
Requirement is that
1) If only one month is there, I should create a transformation with a date column pointing to the last date of that month and the year would be the current year.
Eg May would be 5/30/2015, January would be 1/31/2015
2) If it is having two months, then second month must be taken and the same logic as in Point 1 should be implemented.
Eg May-June would be 6/31/2015, January-February would be 2/28/2015.
My first preference would be without using VBA code.
Please help.
You can use a one-liner in a function:
Public Function GetDateFromMonth(ByVal Months As String) As Date
Dim Ultimo As Date
Ultimo = DateAdd("d", -1, DateAdd("m", 1 + UBound(Split(Months, "-")), CDate(Split(Months, "-")(0) & "/1")))
GetDateFromMonth = Ultimo
End Function
Split the string on the "-", use the second month, add one to that month to get the next month, then take the first day of that month and subtract one from it. For example Jan-Feb : build 3/1/2015 and then subtract 1 day to get the last day of Feb.
Make a table that holds a list of Months:
MonthName MonthNumber
January 1
February 2
March 3
April 4
May 5
June 6
July 7
August 8
September 9
October 10
November 11
December 12
Create this query:
SELECT InputData.Months, DateSerial(Year(Date()),[MonthNumber]+1,0) AS ReqdDate
FROM InputData, Months
WHERE (((IIf(InStr([Months],'-')=0,[Months],Mid([Months],InStr([Months],'-')+1)))=[MonthName]));
That's it. Output looks like this:
Months ReqdDate
May 31/05/2015
May-June 30/06/2015
November 30/11/2015
January-February 28/02/2015
March 31/03/2015
April-September 30/09/2015
Sorry about formatting - noob. I'm in Eu so my dates look odd to you, but you get the idea; you can make them US dates in a moment I'm sure. You can use the bits of this you need in your code in two secs.
If you don't like the lookup table for month number, I'm sure you can use some format function to turn the month name into a month number.