How to write simple select clause for the following problem

Original text of this message