replace non existing bgdi_id column with on the fly conter column

bgdi_id column does not exist in the database.
This pull request is replacing the bgdi_id column in the index source with an on the fly counter.