added paramter handling for insert