* You are viewing Posts Tagged ‘PL/SQL’

Oracle Upsert: Insert or Update

When working with relational data in a stateless environment (e.g. web applications) it is sometimes not known if something is being created (insert) or being updated. This is generally seen when an object has an 0..N number of sub elements.

When the data from the user is to be processed, it would be best to handle both inserting and updating with a single statement. Developers new to databases generally handle this transaction with multiple statements using conditional “IF” statements to determine the number of rows a result set has. Based on the number of rows (0 or 1) an … Continue Reading

OPP 2007 East – Session 5 – Quest Stoftware’s PL/SQL Code Tester

The last session of the day included a first look at Quest Software’s PL/SQL Code Tester which brings something very new and exciting to the world of Oracle development, easy and intuitive regression testing! Very much like JUnit for Java, Code Tester brings a great UI to the user and offers the ability to quickly create test cases.

Of course the skeptics at this point will start spinning their worst PL/SQL function calls in their heads. Attempting to think of the impossibilities of such a task. Be assured cursor variables, collections, and even hierarchal data have all been considered. Granted, the … Continue Reading

OPP – Session 3 – PL/SQL Error Management

Session three turned out to be great! The subject matter was on error handling in PL/SQL and how while Oracle 10gR2 has fixed a few issues with PL/SQL error handling, there is much more that each developer can do to increase the usefulness of errors to developers and the verbosity for users. As a bonus it was given by Steven Feuerstein who has a great presentation style. I will admit I do not agree with everything he presents, but at least he does it in a way that keeps me listening.

What he did covers was usefulness of the DBMS_UTILITY package … Continue Reading