I have a table order_item like this:
| sku | quantity | subtotal |
|-----|----------|----------|
| A | 1 | 25.00 |
| B | 2 | 40.00 |
| C | 3 | 45.00 |
Is there any way to select "unit order_item" rows from order_item with result like:
| sku | unit_price |
|-----|------------|
| A | 25.00 |
| B | 20.00 |
| B | 20.00 |
| C | 15.00 |
| C | 15.00 |
| C | 15.00 |
where the result row counts of a sku is the quantity in order_item and the unit_price is (subtotal/quantity) ?