Shoaib,
I'll just sketch out the answer here - if you need more details you can contact me. The easiest way to do this is to put the equation in matrix form, then use elementary row operations to convert the matrix to echelon form, making sure to perform the same operations on the vector obtained from the right hand side of the equation. Then there is a unique solution if all pivots of the matrix are non-zero.
In this case, there is a unique solution for all but two values of a. For one of those two values, there is no solution, in the other case, there are infinitely many solutions.