search result count and total count was an int, now long. fixes #637