Displaying 1 result from an estimated 1 matches for "buy_order".
Did you mean:
bl_order
2011 Aug 10
0
sql query in a more "rails 3 way"
Hi people
I want to know if you know how to write the following sql query in a
more "rails way"
UPDATE buy_order_detail
SET saldo = saldo - detail_purchase.cantidad
FROM purchase_detail
INNER JOIN purchase ON purchase.id =
purchaser_detail.purchase_id
INNER JOIN waybill ON waybill.id =
purchase.waybill_id
INNER JOIN buy_order ON buy_order.id =
waybill.order_id
INNER...