FOR INSERT:
1.Insert Master table
2.Insert Details tableFor Delete:
1.Delete from Details table
2.Deleta from Master table