The days_between() function determines the truncated number of full days between two timestamps.
int = days_between(timestamp t1, timestamp t2);
The t1 value specifies the beginning timestamp.
The t2 value specifies the ending timestamp.
select days_between('1996-02-27 06:12:33' , '1996-03-01 07:12:33');
DAYS_BETWEEN
--------------
3
(1 row)