web
You’re offline. This is a read only version of the page.
close
Skip to main content
Community site session details

Community site session details

Session Id :

How to get latest record based on the date and time in D365. #x++ #d365 #dynamics

Krishna Bhardwaj Profile Picture Krishna Bhardwaj 97
My requirement was pretty simple, I needed to get the latest record based on the date and time. So I wrote this query to get the required record. 
 
 
 select firstonly SettleAmountCur from vendSettlement
                order by CreatedDateTime desc
                where vendSettlement.OffsetTransVoucher == vendTrans.Voucher
                    && vendSettlement.TransCompany == vendTrans.DataAreaId
                    && vendSettlement.AccountNum == vendTrans.AccountNum;

Comments

*This post is locked for comments