Last Thursday (September the 24th) the Oracle Tools competence team had its monthly Knowledge Day at the office in Nieuwegein. Although we missed some colleagues, who were on vacation, too busy at their projects or otherwise unable to attend, we had a good crowd and were able to get some stuff done.
Best practices for locking
We started as always, discussing some chapters of Tom Kytes great book, covering chapters 6 and 7 about locking and concurrency. How does Oracle handle processing and data integrity when multiple users simultaneously perform operations on the database? And, what should we take into account when designing and developing custom applications.
In recent years the “best practice” for locking has shifted. Initially, mostly with client server applications, Pessimistic Locking was recommended. At the first sign of potential editing the corresponding records were locked using a ‘for update nowait’ in the query. This will ensure that no other user can change the data while it is being edited.
With the rise of web applications, we are advised to use optimistic locking. The records is not locked until the actual change is sent to the database. You will have to check your data first, because another user may have changed the data on the screen in the mean time. To allow optimistic locking, an additional column is added to the table to identify the exact timestamp or the content of the record. The latter can be achieved using a hash value over all columns, using for instance dbms_crypto.hash.
Project experiences with Application Express
Two colleagues who use Apex on their current or previous projects, shared their experiences.
One worked on a project where it was possible to login to the application via internet, allowing clients to view and download the relevant data needed for their monthly reports.
There was also a great demo with drag-and-drop functionality using the libraries of script.aculo.us. We expect to share more details on this in a later article.
Another colleague showed how to build a multilingual Apex application. He is currently building an Internet application in Apex that is to be deployed in The Netherlands, Belgium and Luxembourg. You can imagine that Multilingualism is very important in this case. To help with this, Apex can generate XLIFF files from an application. These files can be translated and then used to make a corresponding page in the new language. Using inheritance mechanisms, generic parts like design are set at a higher level.
Apex do’s and don’ts
I’m sorry, you can’t find the full list of do’s and don’t right here. We are working on it, though. We’ve made a good set of best practices for Application Express which is one of the goals of the Oracle Tools competence.
More about that in the future.


Whitehorses is specialized in succesfully implementing Oracle SOA solutions: BPEL, OSB, WebLogic & BPM