Best Of
Re: Working with Multiple Date Fields
@gilbec01 You could append the leads created and demos scheduled in a dataflow and rename their respective date fields to be called "Date". In this scenario then you can create a constant column to each sub-table called "Activity Type" with a value of "Create" or "Schedule Demo" before appending to differentiate between activities. To calculate conversion rate using the new dataset, you can base your card off of the "Date" column and write a beast mode like the one below:
sum(case when `Activity Type` = 'Schedule Demo' then 1 else 0 end) / sum(case when `Activity Type` = 'Create' then 1 else 0 end)
Re: Combining 2 datasets together
@zuchu I suggest joining your datasets by Quote # rather than appending so that the corresponding quote and sale are on the same row. Then you can create a simple formula like the one below to check whether that quote generated a sale:
case when `Sales.Quote#` is null then 'No' else 'Yes' end
Re: Can you subtract days based on case when statements?
You will want to use the DATE_SUB function to subtract days from a given date. It would look like this:
Case when 'ID' = '1066' THEN DATE_SUB(`Maturity Date`, INTERVAL 45 day) when 'ID' = '1019' THEN DATE_SUB(`Maturity Date`, INTERVAL 55 day) when 'ID' = '2600' THEN DATE_SUB(`Maturity Date`, INTERVAL 66 day) when 'ID' = '2507' THEN DATE_SUB(`Maturity Date`, INTERVAL 70 day) when 'ID' = '1075' THEN DATE_SUB(`Maturity Date`, INTERVAL 75 day) when 'ID' = '2669' THEN DATE_SUB(`Maturity Date`, INTERVAL 85 day) ELSE DATE_SUB(`Maturity Date`, INTERVAL 66 day) END
As far as returning a floating decimal instead of a date, I'm not sure what you would expect to be returned when you are wanting to subtract a number of days from a date.
Re: Format Integer or Text String as Date
Your Calendly date field is being store in millisecond unix timestamp. You can convert it to seconds by dividing by 1000 and then using FROM_UNIXTIME to convert it to an actual datetime type
FROM_UNIXTIMESTAMP(`First Booked Calendly Date`/1000)
Re: How to create a column of data
Hi @DashboardDude , thank you for the help and the video :) and it should be "date"* on the title of my topic, sorry, i wrote it wrong.
Luiza
Re: How can I convert an Excel date code into a normal M/D/Y formatted date?
Hi @HowDoIDomo ,
So the start of that 4** date is Jan 1, 1900 so you need to create a column in an ETL with that Date and then add your number of days to that date. I made a video for you to see:
John Le
You're only one dashboard away.
More video solutions at: https://www.dashboarddudes.com/pantry



