Is there a way where I can set last_number field of sequence of each table in Oracle to the maximum value of the primary key of that table using stored proc?
There are some data mismatch between the current sequence and the max value of primary key, so I am trying to reset the sequence to match that max value of the primary key so it will increment correctly. I am looking to do it via stored proc, and there are many tables so its not feasible for me to manually edit them one by one. Any help would be greatly appreciated!