【发布时间】:2014-10-28 07:06:19
【问题描述】:
SELECT e.qty * e.unit_cost * e.unit_no * (e.factor/100) AS Ext_price, c.cost_type, c.cost_dt, c.internal_cost_amt, c.client_cost_amt
FROM equipment e
LEFT JOIN CostAllocation c ON (c.object_row_id = e.row_id)
我现在想将Ext_price 除以与设备行匹配的CostAllocation 行数。我该怎么做?
【问题讨论】:
-
你能用这个
select返回COUNT(c.object_row_id)并在客户端上做吗?