日期:2014-05-18 浏览次数:20496 次
select modelID,modelName,packageName,content from ( select t2.modelID,t1.modelName,t3.packageName,t2.content,t1.packageID,t3.fiorder t3_fiorder, t1.fiorder t1_fiorder from t3 left join t1 on t3.packageId = t1.packageId left join t2 on t1.modelID t2.modelID ) t order by (case when packageID is null then 1 else 2 end) , t3_fiorder, t1_fiorder