What is the formula for date range in spotfire? - spotfire

I would like to filter my data in spotfire using a date range formula, like this Date > '2020-05-01'
May i know how to write this date rangr using spotfire formula?

The correct syntax would be : [ColumnName] > Date('2020-05-01) This will take your string of '2020-05-01' and convert it to a date which can be used to compare to your date column. This can be used in data limiting expressions in a visual , calculated column or anywhere else an expression can be used.

Related

Creating an Excel formula that takes the date range from a column

I have a table that contains Date column with dates that look like this:
Ex:
In the example above the Excel formula should look at the range and show the following output:
1/23/18 - 1/25/18
How can this be done?
If those are actual dates (and not strings that look like dates), then they are numbers and you can extract the minimum and maximum values in the range, the format them:
=CONCATENATE(TEXT(MIN(A1:A10),"DD/MM/YYYY")," - ",TEXT(MAX(A1:A10),"DD/MM/YYYY"))
(in the above, I assumed the dates were in A1:A10)

Date division on Excel

I am completely new on Excel and trying to do a measurement.
Which is finding the middle age of a END DATE - START DATE/2
Which should be retun as a date format.
I am using this query --
=DATE([End Date]-[Start Date])/2)
Could anyone can correct me with this query please.
You actually don't want to use the DATE formula as has three parameters. What you want to do is (END_DATE-START_DATE)/2 + START_DATE and have the cell containing that have the 'Date' format.

Excel Index & Match with differing date format

I am trying to get use the Index and Match excel function to match and return dates between sets of data. However the issue i have is one set of data uses "m/dd/yyyy" format while the other uses dd/mm/yyyy" format.
See screenshot below of the 2 data to be compared and the dates:
Data1
Data2
Does anyone know how i can use this formula if i have differing set of date formats? or can suggest another formula?

Excel evaluates date as int

I'm trying to match a date against an array. However, I notice my date is evaluated as an integer.
Instead of =MATCH(20/02/2014;B1:B21;1) it becomes =MATCH(41690;B1:B21;1); and I'm getting an #N/A as a result!
How to get this rectified?
Thanks!
Make sure that dates in your lookup column are actually dates (i.e. 5-digit decimal values in fact, but not text).
Use a formula like this:
=MATCH(DATE(2014,2,20),B1:B21,1)
This is because your lookup range is not formatted as Date, because in whatever format you write a date (dd/mm/yy or mm/dd/yy or yy/dd/mm) dates should match if written as date.

Convert text to date in Excel

Currently I exported some data, from a database using a query in which each row for a "comment" column begins with a date formatted as MM/DD/YY.
I used the =LEFT(TEXT,8) function to only extract the date but it happens that the some of the dates are formatted inconsistently so we may have some that are M/D/YY where the month or day isn't two digits, this will then include a ';' as a separator since it is less than 8 characters.
Is there a way I can format the text so the ';' is excluded? That way I can sort the data.
I think the DATEVALUE function does most of what you need. It takes in many different date formats (M/D/YYYY, MM/DD/YYYY etc) and converts it to an excel date (i.e. # of days since 1/1/1900).
The formula below says:
If the date is clean then just apply DATEVALUE function
If there is an error, just use the part to the left of the ';'
Assuming 9/1/2013 is Cell A2:
Input Data Sortable Excel Date
---------- -------------------
9/1/2013; =IFERROR(DATEVALUE(A2),DATEVALUE(LEFT(A2,FIND(";",A2)-1)))
09/2/2013; 9/2/2013
10/1/2013; 10/1/2013
10/10/2013 10/10/2013
I've made a live Excel sample here.
Assuming your text looks like this: ;1/;2/13 or 1/2/13;; or ;;1/2/13
You can use substitute like this:
=SUBSTITUTE(A1,";","")
The result will be:
So if date is either the first 6, 7 or 8 characters of A2 you can get the date with this formula
=LOOKUP(10^10,LEFT(A2,{6,7,8})+0)
format result cell in required date format
As the result is a valid date you can sort these as you would sort numbers

Resources