Cameras deter crime. Not ALL crime. Criminals aren’t stupid and will simply go burgle someone that isn’t recording.
People have been stealing things from stores which have had cctv for decades. Your premises are manifestly false.
CCTV doesn't work well when people feel like nobody is going to bother to check its footage (e.g. pocketing a $2 drink from a big-box department store). But when it comes to homes, there are much higher chances of captured footage being used and examined, so it may cause opportunistic burglars to look at other houses instead.
Just because something doesn’t work 100% of the time doesn’t mean it can’t be effective.
The crime there (shoplifting) doesn't begin until they leave.
In the case of a burglary, the crime begins when they enter.
Seems to be a pretty important distinction when discussing whether knowing a person is physically present on your property alerts you to a crime in progress.