Say I do two insert transactions. Each of them is potentially inserting a large number of rows into a table. (These are actually done from a trigger, if it matters - the table is an audit log.)
I need to be able to guarantee that something - whether primary key, timestamp, etc - will be monotonically increasing. That is, I want something to be able to distinguish between the first insert transaction and the second one. The values don't necessarily have to be the same in all inserted rows within a single transaction - though that would be nice. All I need is to be able to guarantee that all the values I read for the second transaction to commit are greater than any value for the first transaction.
It seems like what I would really like is the value used for multiversioning concurrency. So, I thought that maybe I could use the ORA_ROWSCN. But in my experimentation shows that this value is a smallish number; in fact, it looks equivalent to seconds since the Unix epoch; converted to a timestamp with scn_to_timestamp it shows only second precision.