Use postgres database.  Fix calculation for break index