What determines the selection rules of surface-enhanced Raman spectroscopy?