the wire definitely has the best dialogue, but the shield is a better DRAMA. the wire never hits the crazy high notes the shield does, but the shield never gives you much to think about. the shield knows it's TELEVISION first and foremost and makes an art out of that; the wire considers itself art (not in a pretentious way), and makes tv out of that.
the wire makes you go HMMM; the shield makes you go WHAT THE FUCK. it depends on what you're in the mood for.
Wait what? The Wire hits some amazing high notes in every season except the last one, especially towards the end of seasons.
I can certainly think of some huge Oh Shit moments in The Shield, but I can only think of two (I'm sure anyone who has watched The Shield can guess one of them) that had enormous emotional resonance with me. Whereas The Wire has a multitude of those.
But like I said it's my second favorite show, so overall arguing The Wire v The Shield is sort of like asking who you want to bang: 70s Pam Grier or 70s Claudia Cardinale. You can't lose, just go balls deep and salute your excellent taste