I don't understand what you want but for a session only process, you can use a package package function get number n number :=0; package body get number n:= n+1; begin select max(column) into n from table; end; This is fast, I don't know what other thing you can be thinking on :) 2014-10-15 16:28 GMT-04:00 Ebadi, Abdul <Abdul.Ebadi@xxxxxxxxxx>: > Hi, > > > > We have a need to generate a 10 or 12 digit unique key. Anyone have a > quick function for this? For example: 435A24C1. > > > > We don’t want to use Oracle’s sequences as we are afraid we will run out > of unique ones. We need billions of these keys. > > > > Thanks, > > Abdul > > >