有没有办法将id列更新为某些行的相同值,并自动将其增加到其他某些行,依此类推?因为我试图为同一日期下的订单提供相同的订单ID,然后自动将其递增到另一个日期。对于oracle来说是新的!
这就是我想要的:
order id |album | order date|status|user
1 | yuan | 13-07-17 |final |xyz
1 | ibuki| 13-07-17 |final |xyz
2 | ibuki| 13-07-17 |final |abc
3 | ibuki| 14-07-17 |final |xyz
3 | ibuki| 14-07-17 |final |xyz
这就是我得到的:
order id |album | order date|status|user
1 | yuan | 13-07-17 |final |xyz
1 | ibuki| 13-07-17 |final |xyz
1 | ibuki| 13-07-17 |final |abc
1 | ibuki| 14-07-17 |final |xyz
1 | ibuki| 14-07-17 |final |xyz
其实我无法想到查询!