Added insert calls, and validation