I'm loading data that is formatted as ISO 8601 duration string. Below are some samples from the data set.
Each string always starts with "P," which designates Period, and "T" which designates Time. The rest of the string may contain H (Hours), M (Minutes) or S (Seconds) along with numbers for each time element.
For example, the string "PT1H3M11.312S" represents 1 hour, 3 minutes, 11.312 seconds, which translates to 3791 seconds.
Question: is there a script function that will convert an ISO 8601 duration string to seconds?
I'm hoping there is a function so that I won't have to parse out the time elements individually.