made python file for the searchstatus function in sql