Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How can i know how many day passed betwen 2 dates

Status
Not open for further replies.

AnacondaPower

Technical User
Jan 7, 2002
1
0
0
US
How can i know how many day passed betwen 2 dates.

i'm using interbase sql and i need that.
 
The basic would be:

day1 - day2

look also at: thread756-144302

another way is to put in a stored procedure which runs the query and results the number
S. van Els
SAvanEls@cq-link.sr
 
var
currentdate, pastdate : Tdate;
result : variant;
begin
result := strtodate(currentdate) - strtodate(pastdate);
formatDateTime('d', result);
end;
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top