Basically: When did police become their own organizational entity as a means to guard individual cities/states as opposed to a duty or regiment of the grander, national military?
The two aren't necessarily separated, you know. Lots of places, like Spain (the Guardia Civil), or Italy (the Carabinieri) still use military regiments for policing duty.