F_AGEINDAYS

<< F_AGEINWEEKSNISO | IBExpert UDF Functions | F_AGEINDAYSN >>

F_AGEINDAYS

 

substitutable with DATEADD

  • compatibility to FreeUDFLib, FreeUDFLib AvERP
  • input/output-compatibility to rFunc (DAYSBETWEEN)
  • Compatible with UTF-8
  • Input TIMESTAMP (older) date optionally time 1, TIMESTAMP (newer) date optionally time 2
  • difference in (integer) days between timestamp 1 and timestamp 2

if you want a negative number if the first date is newer than the second date

Example

 SELECT 10 AS ISCORRECT, F_AGEINDAYS('01.10.2018 15:01:03','11.10.2018 15:04:03') FROM RDB$DATABASE;

Expected results:

    ISCORRECT  F_AGEINDAYS
 ============ ============
           10           10

Example

 SELECT -20 AS ISCORRECT, F_AGEINDAYS('01.10.2018 15:01:03','11.09.2018 15:04:03') FROM RDB$DATABASE;

Expected results:

    ISCORRECT  F_AGEINDAYS
 ============ ============
          -20          -20

back to top of page
<< F_AGEINWEEKSNISO | IBExpert UDF Functions | F_AGEINDAYSN >>