Om op te maken hoe datum- en tijdstempelvariabelen of uitgangen binnen een keten moeten verschijnen, kunt u een transformatie Parse Date/Time toepassen, en de waarde instellen als string format time (strftime).
<!--<ul> <li> Paste the raw transformation as the command property's value. </li> </ul>String format time
To use a Parse Date/Time transformation to set the format of a date or timestamp, enter its values as strftime.
-->Datumwaarden
| Waarde | Voorbeeld | strftime |
|---|---|---|
| Naam volledige dag | Zondag |
%A |
| Afgekorte dagnaam | Zon |
%a |
| Dag van de week | 0 tot 6, waarbij zondag 0 is |
%w |
| Jaar met twee cijfers | 21 |
%y |
| Viercijferig jaar | 2021 |
%Y |
| Volledige maandnaam | Januari |
%B |
| Afgekorte maandnaam | Jan |
%b |
| Maand met twee cijfers | 01 tot 12, januari tot december |
%m |
| Twee-cijferige dag van de maand | 01 tot 31 |
%d |
| Dag van de maand zonder voorloopnul | 1 naar 31 |
%e |
U kunt deze waarden aan elkaar rijgen om een datumnotatie in te stellen. Bijvoorbeeld:
| Datum formaat | Voorbeeld | strftime |
|---|---|---|
| mm/dd/jjjj | 12/01/2021 |
%m/%d/%Y |
| [Volledige dagnaam], [volledige maandnaam] [dag van de maand zonder voorloopnul], [viercijferig jaartal] | Woensdag 1 december 2021 |
%A, %B %e, %Y |
| [Afgekorte maandnaam] [dag van de maand zonder voorloopnul] [afgekorte dagnaam] | 1 dec Wed |
%b %e %a |
Tijdswaarden
| Waarde | Voorbeeld | strftime |
|---|---|---|
| Uur van 24-uursklok | 00 tot 23 |
%H |
| Uur van 12-uursklok | 01 tot 12 |
%I |
| Uur van 12-uursklok zonder voorloopnul | 1 naar 12 |
%1 |
| Minuut | 00 tot 59 |
%M |
| Tweede | 00 tot 60 |
%S |
| Ante of post meridium | AM of PM |
%p |
| Tijdzone | +08 |
%Z |
| Dag van het jaar | 001 tot 366 |
%m |
| Procent teken | % |
%% |
U kunt deze waarden aan elkaar rijgen om een tijdnotatie in te stellen. Bijvoorbeeld:
| Datum formaat | Voorbeeld | strftime |
|---|---|---|
| HH:MM in 24-uursklok | 23:01 |
%H:%M |
| H:MM in 12-uursklok, met ante of post meridium | 4:31 PM |
%1:%M %p |
Raw transformations
Rather than apply a transformation to a variable or output used as a command property, you can copy and paste these raw transformations in the command property:
<h3>Timestamp</h3>For a full date and timestamp value, such as 2021-03-15T16:04:28.744118Z:
<pre>$(Chain.ExecutionDateTime)</pre> <h3>Time</h3>For the hour and minutes, such as 1610:
<pre>$(Chain.ExecutionDateTime)@transform{parseDateTimeOC_SPLIT%FT%T.%fZOC_ARG%H%MOC_ARGOC_ARGOC_ARG}</pre>For the hour, minutes, and seconds, such as 161051:
<pre>$(Chain.ExecutionDateTime)@transform{parseDateTimeOC_SPLIT%FT%T.%fZOC_ARG%H%M%SOC_ARGOC_ARGOC_ARG}</pre> <h3>Date</h3>With date values, the raw transformation can set the format for the current date or include subtractions to set previous years' values.
<h4>Current year</h4>For the current, four-digit year:
<pre>$(Chain.ExecutionDateTime)@transform{parseDateTimeOC_SPLIT%FT%T.%fZOC_ARG%YOC_ARGOC_ARGOC_ARG}</pre>For the current month and four-digit year:
<pre>$(Chain.ExecutionDateTime)@transform{parseDateTimeOC_SPLIT%FT%T.%fZOC_ARG%m%YOC_ARGOC_ARGOC_ARG}</pre>For the full current date, starting with the day, such as 31102021:
<pre>$(Chain.ExecutionDateTime)@transform{parseDateTimeOC_SPLIT%FT%T.%fZOC_ARG%d%m%YOC_ARGOC_ARGOC_ARG}</pre>For the full current date, starting with the month, such as 10312021:
<pre>$(Chain.ExecutionDateTime)@transform{parseDateTimeOC_SPLIT%FT%T.%fZOC_ARG%m%d%YOC_ARGOC_ARGOC_ARG}</pre> <h4>Previous year</h4>For the previous, four-digit year:
<pre>$(Chain.ExecutionDateTime)@transform{dateMathOC_SPLIT%FT%T.%fZOC_ARGsubtractOC_ARG1OC_ARGyearsOC_ARG}@transform{parseDateTimeOC_SPLIT%FT%T.%fZOC_ARG%YOC_ARGOC_ARGOC_ARG}</pre>For the current month a year ago:
<pre>$(Chain.ExecutionDateTime)@transform{dateMathOC_SPLIT%FT%T.%fZOC_ARGsubtractOC_ARG1OC_ARGyearsOC_ARG}@transform{parseDateTimeOC_SPLIT%FT%T.%fZOC_ARG%m%YOC_ARGOC_ARGOC_ARG}</pre>For the current date a year ago, starting with the day, such as 31102020:
<pre>$(Chain.ExecutionDateTime)@transform{dateMathOC_SPLIT%FT%T.%fZOC_ARGsubtractOC_ARG1OC_ARGyearsOC_ARG}@transform{parseDateTimeOC_SPLIT%FT%T.%fZOC_ARG%d%m%YOC_ARGOC_ARGOC_ARG}</pre>For the current date a year ago, starting with the month, such as 10312020:
<pre>$(Chain.ExecutionDateTime)@transform{dateMathOC_SPLIT%FT%T.%fZOC_ARGsubtractOC_ARG1OC_ARGyearsOC_ARG}@transform{parseDateTimeOC_SPLIT%FT%T.%fZOC_ARG%m%d%YOC_ARGOC_ARGOC_ARG}</pre> <h4>The year before last</h4>For the four-digit year, two years ago:
<pre>$(Chain.ExecutionDateTime)@transform{dateMathOC_SPLIT%FT%T.%fZOC_ARGsubtractOC_ARG2OC_ARGyearsOC_ARG}@transform{parseDateTimeOC_SPLIT%FT%T.%fZOC_ARG%YOC_ARGOC_ARGOC_ARG}</pre>For the current month two years ago:
<pre>$(Chain.ExecutionDateTime)@transform{dateMathOC_SPLIT%FT%T.%fZOC_ARGsubtractOC_ARG2OC_ARGyearsOC_ARG}@transform{parseDateTimeOC_SPLIT%FT%T.%fZOC_ARG%m%YOC_ARGOC_ARGOC_ARG}</pre>For the current date two years ago, starting with the day, such as 31102019:
<pre>$(Chain.ExecutionDateTime)@transform{dateMathOC_SPLIT%FT%T.%fZOC_ARGsubtractOC_ARG2OC_ARGyearsOC_ARG}@transform{parseDateTimeOC_SPLIT%FT%T.%fZOC_ARG%d%m%YOC_ARGOC_ARGOC_ARG}</pre>For the current date a year ago, starting with the month, such as 10312019:
<pre>$(Chain.ExecutionDateTime)@transform{dateMathOC_SPLIT%FT%T.%fZOC_ARGsubtractOC_ARG2OC_ARGyearsOC_ARG}@transform{parseDateTimeOC_SPLIT%FT%T.%fZOC_ARG%m%d%YOC_ARGOC_ARGOC_ARG}</pre> -->