14 lines
440 B
Plaintext
Raw Normal View History

<h3>to_interval() function</h3>
2013-05-11 13:15:59 +10:00
Converts a string to a interval type. Can be used to take days, hours, month, etc off a date.
<h4>Syntax</h4>
<code>to_interval('string')</code><br>
2013-05-11 13:15:59 +10:00
<h4>Arguments</h4>
<code>string</code> - is string. Format {n} days {n} hours {n} months
<br>
<h4>Example</h4>
<!-- Show example of function.-->
<code>todatetime('2012-05-05 12:00:00') - to_interval('1 day 2 hours') &rarr; 2012-05-04T10:00:00</code><br>