I Have a 2 Tables lets say Department and Employee. Parent :- Department Child:- Employee
in Department mapping file Employee list bag created.
In employee table i have a column as "IsDeleted", we used this for deleted records because our client wants like this to not delete permanatly.
My problem is when i retrieve the department with session criteria automatically the list of employee records also will retrieve for each department this is fine. But in employee the records are coming deleted also, but i need non-deleted records only when i retrieve "Department" table.
Please help me on this. I don't want to write any query and no need to loop for each records wheather this employee record is delete or not.
I need like this
"CreateCriteria(typeof(Department)).Add(Expression.Eq"
Scenario only. Please help me.
|