Kumar,
I want to know the difference between Creation of Credit Memo with reference to Sales Order & with reference to Invoice.
Let me clarify one point; is your question in what business situations we create
a) a credit memo with reference to a billing document
b) a credit memo with reference to a credit memo request (order)?
Before giving money back to the customer, if the company wants to do a check; this can be done by following option b.
The check is done by putting a billing block in the credit memo request.
If the money taken from the customer via a billing document has to be entirely and "immediately" given back to the customer, then this can be done by following option a.