The Altair Community is migrating to a new platform to provide a better experience for you. In preparation for the migration, the Altair Community is on read-only mode from October 28 - November 6, 2024. Technical support via cases will continue to work as is. For any urgent requests from Students/Faculty members, please submit the form linked here
Multiple Nominal to Date conversions
Hello,
I'm currently working in a file that will need multiple 'Nominal to Date' operators for multiple columns. Is there an operator that I would be able use to do all of the conversions or would I need to use an opeartor per column(field)?
TIA
Tagged:
0
Answers
@mtran how are you loading the data? If you're doing it via a flat file like CSV or XLS, you can set the attribute column as a date-time format on load. If not, you could try a 'Guess Types' operator but I'm not sure if that will work.
@Thomas_Ott Thanks for the quick reply. I noticed I was able to set the data types to 'Date' when using flat files but one of the guys on my team is pulling data in from SQL server.
You can use the Loop Attributes operator to loop through each date field and use nominal-to-date in one hit.
(Remember to check reuse results) - if using Macros for the attributes then this process can be really easily reused.
I'm sure I recall seeing @awchisholm using a bit of Groovy script for this type of conversion before as well.