Hi,
I tried to have a deffrence between 2 dates in SAP B1 Using UDF, but it dosn't work;
this is the query i used ;
declare @D1 datetime
declare @D2 datetime
set @D1 =(select CONVERT(date,$[$12.0.0],104))
set @D2 = (select CONVERT(date,$[$10.0.0],104))
SELECT distinct datediff(month,@d1,@d2) as 'Date Diffrence'
Any idea plz ?