Sometimes when you’re writing code you can encounter the situation only one session / thread may execute it (the code) at a time. This is commonly referred as a “Critial Section“. How do you solve such a problem within the Oracle Database?
Continue reading “Have only one session execute code (Critical section)”Tag: PL/SQL
Debugging via Dbms_Pipe
When running code you sometimes have the need to debug the progress of the statements. One way is to use a table and write your debug output into it by means of an autonomous transaction. But sometimes it can be easier to just hand the debug info to a different session. Say hi to Dbms_Pipe…
Continue reading “Debugging via Dbms_Pipe”Using unicode characters in PL/SQL
Sometimes you need to use unicode characters in messages / strings you output from PL/SQL code. However sometimes the automatic installation procedures of a customer might use a different or weird character-set when installing your code into the database. What happens is that the character within the source (in a constant for example) becomes mangled and appears as a “character not recognised question mark” in the output.
Continue reading “Using unicode characters in PL/SQL”