Clean up book, use sql_calc_found_rows instead of count on predb.