changed recordset hierarchy for templates
added deletionPolicy enum