Subject Re: [firebird-support] dates difference function
Author Ivan Prenosil
> Hi! I'm trying to calculate a dates difference in a stored procedure in InterBase 7.5:
> given two dates in dd/mm/yyyy format

Do you mean you store dates as strings ??

> I need its difference in days,
> like this one in SQL 2000:
>
> set @Days = (SELECT DATEDIFF(DAY,@val1, @val2))
>
> is there a predefined function to do that?

Just subtract them.
Days = Date1 - Date2;

Ivan