Converts string to date. Useful when date or datetime from Sugar is needed to send to an external resource with a format that differs from the Sugar date/datetime format.
If you use Date or Datetime Type fields to compose API requests (using Rest Client operator), then you need to use Get String From Date operator in order to format dates properly.
inputs:
date – link with a date or datetime that is needed to convert in another format
- Required: yes
format – specify the format of the convert – how date should be represented in result. The full list of allowed date formats you can find here.
- Required: yes
Most common formats:
When the resulting date in a string must look like this… | …use this format |
2021-11-27 23:04:13 | Y-m-d H:i:s |
27/11/2021 17:45:12 | d/m/Y H:i:s |
27/11/21 | d/m/y |
1637849455 | U |
2021-11-27T15:19:21+00:00 | c |
outputs:
string – date represented as a string converted from the date input using the specified format
Click to rate this post!
[Total: 0 Average: 0]