And let's be specific about what we're talking about here. A Miranda violation is not a get out of jail free card. Even if the judge/appellate court finds that your 5A rights were violated because you weren't properly Mirandized, it does not mean you necessarily walk away. At the trial level, it simply means that the prosecutor cannot use or refer to any statements you may have made after the moment when you were supposed to have been Mirandized and were not - and the appellate court may, of course, order a new trial and specify that such statements be excluded from presentation in the retrial.
But it's rare that a Miranda violation will inherently result in a prejudicial dismissal (prejudicial dismissal means the case cannot be retried).
But it's rare that a Miranda violation will inherently result in a prejudicial dismissal (prejudicial dismissal means the case cannot be retried).