Performance considerations

Compared to the performance of incrementing a sequence at the primary database, particularly where sequence values are cached, the effort to increment the same sequence at the standby site may be less efficient. The stored procedure must dynamically determine the sequence to increment and then loop internally, incrementing the sequence until the primary value has been reached. (The loop is required because there is no way to assign a specific value to a sequence.)

Because the name of the sequence is passed as a parameter, Oracle cannot pre-compile the procedure for efficiency. With the addition of the looping activity, the performance of the solution may impact some environments where a large number of highly used sequences is the norm.