As you have discovered, the API presents the raw solution string and not the calculated string with variables replaced. This happens for a number of reasons; the UI is aware of interface / language, calculations or other variable changes at run time, and more. Therefore, the SOAP API isn't aware of the context of the variable to replace it at query time through ROQL. Depending on how your variable is constructed, you would probably need to programmatically replace the variables based on logic behind that variable in your answer.
As a side note, selecting all answers through an object query (instead of a tabular query for just the fields that you want) can be expensive (technically). What's the business case behind selecting all answers in this way?