Cost-Based Query Optimization in a Heterogeneous Distributed Semi-Structured Environment