changes to help db query peformance