1
我使用索引centerLatitude和centerLongitude這些代碼,一些regionID 犯規有centerLatitude和centerLongitude,其分配什麼,但想爲 centerLatitude和centerLongitude分配0,0如果regionID可是沒有它將一個默認值,而索引時間爲Apache Solr實現
select <entity name="PropertyRegionID"
query="SELECT IFNULL(r.RegionID, 0) as RegionID from ParentRegionList as r">
<field column="RegionID" name="RegionID" />
<entity name="PropertyRegionCenterCoordinates"
query="SELECT IFNULL(cnt.centerLatitude, 0) as centerLatitude, IFNULL(cnt.centerLongitude, 0) as centerLongitude from RegionCenterCoordinatesList as cnt WHERE cnt.RegionID=${PropertyRegionID.RegionID}">
<field column="centerLatitude" name="centerLatitude" />
<field column="centerLongitude" name="centerLongitude" />
</entity>
</entity>
任何建議
謝謝,它的工作 – 2014-10-20 11:58:25