kev374 wrote:If the primary key is a sequence - No (not safe) and yes (it is wrong). As using a sequence is the wrong value/type to use - as rp0428 explained pretty well.
All I was asking was if one can safely infer chronological order from a primary key and if there is anything wrong with doing this.
Sometimes, two rows have the exact same created_date down to the millisecond and are displayed in the UI in the wrong order.Given that the dates are exactly the same, how do you determine that they are in the "wrong" order? Perhaps you can add whatever that is to the orfer by condition.
kev374 wrote:That's not how oracle itself keeps track of the order of transactions .... it uses a sequential number, aka SCN.
. . . I think the chronological order of records should be using a timestamp
(i.e. "order by created_date desc" etc.) but perhaps the mid-tier should put in a millisecond delay so two records don't have the same timestamp to the millisecond.Can you spell 'backlog'?