Fixing indexing for app DB.