title: Writing complex stored procedures in H2 database
body: <p>I have an oracle stored procedure in which first of all I am opening a cursor with complex select query using "cases" and later iterating the cursor and then inserting or updating the records based on some condition. I want this to be written in H2 database.</p>