Hi,
I need to concatenate string and date time. But I am getting error. I assume I need to convert first the format from datetime to string. But I can’t find the way how to do it.
thanks
Maros
Hi,
I need to concatenate string and date time. But I am getting error. I assume I need to convert first the format from datetime to string. But I can’t find the way how to do it.
thanks
Maros
Hi @maros
Welcome to the eazyBI community.
In general, you could try using the format() function to convert date to string.
Try this example
CASE WHEN
Not IsEmpty([Measures].[Issue created date])
THEN
(
"created at:"||
format([Measures].[Issue created date], "yyyy-dd-mm")
||", resolved at:"||
format([Measures].[Issue resolution date], "yyyy-dd-mm")
)
END
See the attached image below!
it would concatenate created and resolved dates into a string and show results only if created date exists.
Martins / eazyBI support
Hi @martins.vanags
Is this possible generate line break ?
For example:
Create at: yyyy-dd-mm
— Line Break —
Resolved at "yyyy-dd-mm
Yes, it is possible to generate brakes using chr(10)
CASE WHEN
Not IsEmpty([Measures].[Issue created date])
THEN
(
"created at:"||
format([Measures].[Issue created date], "yyyy-dd-mm")
|| chr(10)
||"resolved at:"||
format([Measures].[Issue resolution date], "yyyy-dd-mm")
)
END
Martins / eazyBI
Thanks for the solution,
I leave this comment in case it is useful to someone else, if you want to go from 2024-01-29 to Jan 29 2024 you have to change what Martins to ‘MMM dd yyyy’