Can you describe the primary differences between SQL and NoSQL databases and when you would choose one over the other?