Before Polk, the United States and Mexico had boundaries along the Rio Grande River. Texas and Polk claimed that America's southern border ran down to the river south of the United States' positon back then. They had a war, but Mexico lost and U.S kept expanding.
Hope this helps!