Modified profiling in ORM
Minor fixes