updates scope and table view