So David gathered all the army together and went to Rabbah; he fought against the city and captured it.