In a service-oriented grid environment, how to discover the desired service easily and well is a prime concern since the service providers are selfish and owned by different organization. In this paper, we suggest a reputation based mechanism to implement service selection in the service-oriented grid. The working model and functionality offered by the proposed reputation service are discussed. We design a service contexts related reputation function and show how the reputation values can be calculated and updated. Finally we conduct an evaluation of our solution, which shows satisfying enough results in an experiment grid.