Bug fixes

Fixed sql glitch with add/edit child