oracle tutorial webinars


One of the greatest achievements of Oracle database software is its ability to process massive sums of information into a multitude of tables and functions. The downside is that in any system, dealing with huge amounts of data can naturally carry some headaches and frustration along the way. The ORA-12801 would most easily fall into this category, an Oracle error emanating most often in response to errors when processing large jobs.

The Problem

The ORA-12801 is an Oracle error that has some confusing origins, but is described as an error resulting in some form from a parallel query server. The error frequently accompanies another error, often the ORA-01652 (which concerns an inability to extend the temp segment in a tablespace). The ORA-12801 is essentially a general error, a sort of catchall for parallel query issues.

At this juncture, some of you may be wondering yourselves, “What is a parallel query?” First showing up in later versions of Oracle7, a parallel query option lets multiple processes request and receive data and perform operations at the same time. As you would imagine, this can greatly enhance the speed of the system. To achieve this kind of efficiency, there are several conditions for the parallel query that require attention. So what are those conditions and how do they pertain to resolving an ORA-12801 error?

The Solution

An absolutely crucial element in successful parallel query operation is the appropriate use of query slaves. If too few or too many are put to use, the system will receive little advantage from their presence. Generally, a good rule to follow is duplicate the number of disks or computers that the operation is used across, and set that as your number of parallel query slaves. Additionally, your tables should account for the parallel query. Run a full table scan to assess the timing of various settings for the degrees of parallel function to determine the best variable size for your performance.

Due to the nature of the ORA-12801, it’s a good idea to examine the error more closely. Set the event to 10397 to gather up information on the error (including the cause, action and some simple comments). You can also check out trace files in the BACKGROUND_DUMP_TEST and USER_DUMP_TEST for more details, as well as your alert.log. You will typically be given a parallel query server number in the error that will give an idea of how many processes are being run, hopefully reminding your of the aforementioned rule of thumb in keeping your query slave numbers at a level that can accommodate your operation. When accompanied with an error such as ORA-01652, you can typically increase the size of your sort_area_size or TEMP tablespace to allow for the job to run effectively.

Looking forward

Avoiding an ORA-12801 can be complicated, but should you remain cognizant of your parallel query operations and know the basics of investigating your system, you should be okay. Staying on top of parallel queries and ensuring that the proper amount of slave and table degree variables are allocated to the job can go a long way in preventing this (and several other) errors. Furthermore, by referring to your alert.log and dump tests from time to time, you can spot the origins of potential errors or obtain additional information of a pending error that is proving to be enigmatic. If you find that generic system errors such as the ORA-12801 are still tripping you up, it wouldn’t hurt to contact a licensed Oracle consultant to assist you with these problems and optimize your experience with Oracle products.