One can define sociology as the study of the development, structure, interaction, and collective behavior of organized groups of human beings.
When it comes to how it differs between religion and reason, it can have many different assumptions. Where as in religion, it can defined as being the service and worship of God or the supernatural, and with reason, it can be defined as being the power of comprehending, inferring, or thinking in orderly rational ways. It is with the two given definitions given, that one can come to the conclusion that religion can be interpreted as a form of reason.
It is also through the general understanding of sociology that we look at sociology as being something that doesn't require specific qualifications; such as being taught what a person knows; but it can be viewed as an acquired knowledge through observations of others within their own society and our society.
Depending on ones religious beliefs, religion, within in a lot of people, is what they have been told, or what they have been taught and learned. Unlike sociology, you can not observe religion other than going to church and being taught what you know, versus learning through observation like with sociology
To determine how sociology differs between religion and reason, the point can be argued that religion is gathered through knowledge, knowledge that you acquire from your religious beliefs regardless of your religion. Where as with sociology; it is merely an understanding; an understanding of a group of people through observation and your own interpretation.