script to parse the log and stick it in the database