Has any city been partially captured?

That title will take a little explaining. What I want to know is whether any army has ever conquered by force a portion of a dense urban area and then successfully held that portion against attack from the other parts of the city, without having to conquer, destroy, or depopulate the entire city? West Berlin doesn’t count because it wasn’t actually attacked.

I assume you don’t mean something like Stalingrad during WWII where the city was under seige by the Nazis. I’m sure they held parts of the city for periods of time, but ultimately they pulled back.

I’m going with Beruit, Lebanon

How about Nicosia (Cyprus)? - the division was performed by military force.

I was there (well, in Cyprus) while it was happening - I was about 7 years old.

Jerusalem comes to mind. The 1948 war ended with the city divided between Israeli and Arab forces, and it was not re-united until the 1967 war.

And I’m guessing you don’t mean something like the Warsaw Uprising of 1943, where the Germans had conquered the entire city, only to be driven out of the Jewish quarter, and had to fight their way back to crush the rebellion.

Then there’s Jerusalem. The first Arab-Israeli war (1948) ended with a cease-fire line running right through the city. Israel hung on to West Jerusalem while Jordan annexed East Jerusalem. It stayed that way until 1967, when Israel captured East Jerusalem.

In World War 2 Trieste was attacked by both allied troops from the north and Yugoslave resistance fighters from the south. Some troops surrendered to the Allies, others to the Yugoslavs. After the war, part of the area wound up annexed to Italy, the other part to Yugoslavia.

Warsaw Ghetto Uprising of 1943. Not to be confused with Warsaw Uprising of 1944.

Yeah, uprising is national sport here.

How about a city with a river running through it?

Most of them weren’t divided by war, but for what it’s worth, here’s a list of divided cities: List of divided cities - Wikipedia

In 1648 the Swedish army captured only the half of Prague on the left bank of the Vltava. Except that this isn’t really an example of what the OP is looking for. Quite apart from the fact that the Peace of Westphalia intervened, the Swedes had never had any intention of retaining control of the city; the attack was no more than a final chance to seize some plunder. But they had tried and failed to take the rest of the city.

There is Rome in 1870. But it was hardly for military reasons that the Italian army failed to take the Vatican.

In 387 BCE, Celts sacked Rome, but failed to take Capitoline Hill. I have a hazy memory that the attack was revenge for Roman forces (who had hired Celtic mercenaries) that fled the field of battle, leaving the Celts to fight on their own. Wikipedia has no mention of that that I could find in a cursory search, though, so I may be conflating it with something else.