Days Compute

1. Hangin Around,,,
Join Date
Nov 2000
Location
Israel
Posts
268
Hi,
i have a table with date type column.
how can i compute the days between current date and the date in the table ?
thanx
Rotem.

2. Substract the dates:

SELECT sysdate-date_column
FROM your_table;

This gives you difference in days between date_column and sysdate;

SELECT (sysdate-date_column)*(24*60*60)
FROM your_table;
gives you get the difference in seconds.

3. Hangin Around,,,
Join Date
Nov 2000
Location
Israel
Posts
268
Sorry,
I ment how do i compute the minutes ???
Thanx.

4. Member
Join Date
Feb 2001
Posts
103
SELECT sysdate-date_column
FROM your_table;

This gives you difference in days between date_column and sysdate;

SELECT (sysdate-date_column)*(24*60)
FROM your_table;
gives you get the difference in minutes

5. Member
Join Date
Feb 2001
Posts
103
Substract the dates:

SELECT sysdate-date_column
FROM your_table;

This gives you difference in days between date_column and sysdate;

SELECT (sysdate-date_column)*(24*60)
FROM your_table;
gives you get the difference in minutes.

6. Hangin Around,,,
Join Date
Nov 2000
Location
Israel
Posts
268
thanx everyone.

#### Posting Permissions

• You may not post new threads
• You may not post replies
• You may not post attachments
• You may not edit your posts
•