Updated search and initialize

Changed primary key of History to ID