DB2 SQL-Error: -845
SQLState: 51035
Short Description: A PREVIOUS VALUE EXPRESSION CANNOT BE USED BEFORE THE NEXT VALUE EXPRESSION GENERATES A VALUE IN THE CURRENT APPLICATION PROCESS FOR SEQUENCE
A PREVIOUS VALUE expression specified sequence sequence-name, but a value has not yet been generated for this sequence. A NEXT VALUE expression must be issued in this application process to generate a value for this sequence before a PREVIOUS VALUE expression for the sequence can be issued. This error can also occur after a sequence has been dropped, and the DROP statement is rolled back. System action: The statement cannot be executed. Programmer response: Issue at least one NEXT VALUE expression for a sequence before issuing any PREVIOUS VALUE expression for the same sequence in a connection.