speed up searches on subject

subject searches are fairly common, so this adds an index if the database
mode is mostly-reading or advanced-reading