hi
if u haven't find yet to get the difference btn dates,
just simply define two dates in different variables & print the difference.
e.g. date d1=12\2\2008;
       date d2=15\2\2008;
       print d2-d1;
       pause;


 byeee...




________________________________
From: larrybellou <[EMAIL PROTECTED]>
To: development-axapta@yahoogroups.com
Sent: Wednesday, 3 December, 2008 8:37:56 PM
Subject: [development-axapta] datediff equivalent in X++


How can I figure out the difference in # of days between two dates?

Can it be done using a select statement as well?

The following t-sql is what I am trying to accomplish but if you can 
answer one or both of the above questions would help me get there as 
well..

T-SQL
select avg(datediff( day, transdate, closed)) from custtrans ct (nolock) 
where accountnum=' aa122'and closed > '1/1/1900'  and dataareaid=' demo' 
and amountmst>0 and transdate >= getdate()-90 

select custTrans where 
localCustTrans. AccountNum= ='ba368'
&& localCustTrans. Closed != datenull() 
&& localCustTrans. AmountMST > 0
&& localCustTrans. TransDate >= systemdateget( )-90;

    


      From Chandigarh to Chennai - find friends all over India. Go to 
http://in.promos.yahoo.com/groups/citygroups/

[Non-text portions of this message have been removed]

Reply via email to