fixed insert, edit needs work