Is there a built in function for retrieving the next value of asequence and updating the sequence counter?