Question Krishnaveni Kapu · Apr 22, 2024 convert dd/mm/yyyy --> yyyymmdd #Key Question #ObjectScript #Caché #Ensemble #Health Connect #InterSystems IRIS #InterSystems IRIS for Health I need to convert dd/mm/yyyy --> yyyymmdd example Input = 25/03/1988 expected Output = 19880325
Iryna Mykhailova · Apr 22, 2024 You can use two conversions: $zdate($zdateh("25/03/1988", 4), 8)ObjectScriptObjectScript
Scott Roth · Apr 22, 2024 ConvertDateTime works well... Ens.Util.FunctionSet (ENSLIB namespace) - InterSystems IRIS Data Platform 2024.1 - including private class members when you call it within a DTL you can specify the incoming and outgoing formats like ..."%d/%m/%Y", "%Y%m%d"
You can use two conversions:
$zdate($zdateh("25/03/1988", 4), 8)
ConvertDateTime works well...
Ens.Util.FunctionSet (ENSLIB namespace) - InterSystems IRIS Data Platform 2024.1 - including private class members
when you call it within a DTL you can specify the incoming and outgoing formats like ..."%d/%m/%Y", "%Y%m%d"
USER>w $tr("CcYyMmDd","Dd/Mm/CcYy","25/03/1988")
19880325
💡 This question is considered a Key Question. More details here.