i have a situation here where i need to pass the date as sysdate of db from the .net code using the Nhibernate here goes my code
OfflineStatusChangeMonitor newstatusobj = new OfflineStatusChangeMonitor
{
NIK = demoFromDedup.NIK,
NIKStatus = new Status { Code = demoFromDedup.CurrentStatus.Code },
RegionId = Convert.ToInt16(demoFromDedup.RegionId),
LocalId = demoFromDedup.LocalId,
Updatedtime = DateTime.Now,
ServiceName = "XXXXX"
};
idmsRepository.Add<OfflineStatusChangeMonitor>(newstatusobj);
where add functions code is as follows
public void Add<ENTITY>(ENTITY entity) where ENTITY : EntityBase
{
this.UnitOfWork.CurrentSession.Save(entity);
}
now in this situation how can i set the values of updatedtime to SYSDATE of Oracle
i can not do it in the data base as i have the db s in many locations and am updating the data from wcf service
and then call this function to get the db date and then use this as the date time in your function