DB: add find_jobs method

This will allow us to search for jobs in particular states.  More
querying options can be added as required.