added the analysis sql insertion