‘ORA-19909: datafile 1 belongs to an orphan incarnation’ during duplicate for standby
Some time ago my colleague Pavel Tolstorukov asked me for help with failing DUPLICATE TARGET DATABASE FOR STANDBY FROM ACTIVE DATABASE. The problem appeared during the recovery phase. The exact error looked like below: We worked on this together and were able to identify the…
Data Guard – Definition of Online Redo Logs is “broken” after duplicate for standby
Hi there, today is the 1st birthday of a service request with Oracle I opened for which I see no progress since quite a while. I raised it exactly one year ago, on Oct 2nd 2019. There were some activity in last October, November mostly…
Disable Formatter for Code Sections in SQL Developer
In this blog post I show how you can disable the formatter for some parts of your code. IntelliJ IDEA and the Eclipse IDE use tags in comments to identify sections of code that must not be formatted. By default these tags are @formatter:off and…
Highlight Hints in SQL Developer
Introduction In this blog post I explain how you can configure your SQL Developer to highlight hints and distinguish them from ordinary comments. The SQL Language Reference for Oracle Database 19c defines hints as follows: Hints are comments in a SQL statement that pass instructions…
TNS chaos
I like to have my Oracle Net config consistent and without surprises. So for me it is a best practice to have ONE central TNS_ADMIN directory on the database server, which is set in all my shells. But a lot of processes might ignore that…
Formatting SQL Code Blocks in Markdown Files
Introduction Everything Changes. Our Trivadis SQL & PL/SQL Coding Guidelines are no exceptions. We plan to change rule #1 of our coding styles. From “Keywords are written uppercase, names are written in lowercase.” to “Keywords and names are written in lowercase.“. We have 103 Markdown…
Always Free Autonomous JSON Database?
Introduction Oracle just released the Autonomous JSON Database (AJD). This is a special version of the Autonomous Transaction Processing (ATP) database focussing on managing JSON documents via Simple Oracle Document Access (SODA) and SQL. Beda Hammerschmidt shows in this blog post how you can use…
Data Guard, Easy Connect and the Observer for multiple configurations
EZConnect One of the challenges of automation in bin Oracle Environments is dealing with tnsnames.ora files. These files might grow big and are sometimes hard to distribute/maintain properly. The worst is when manual modifications are needed: manual operations, if not made carefully, can screw up…
Script to check Data Guard status from SQL
In a previous blog post I have explained how to get the basic configuration from x$drc and display something like: OBJECT_ID DATABASE INTENDED_STATE CONNECT_STRING ENABLED ROLE RECEIVE_FROM SHIP_TO FSFOVALIDITY STATUS ——— ————– —————– —————————- ——- ——– ———— ————– ———— ——- 16842752 toolcdb1_site1 READ-WRITE-XPTON newbox01:1521/TOOLCDB1_SITE1 YES…
Script to check Data Guard status from SQL
In a previous blog post I have explained how to get the basic configuration from x$drc and display something like: OBJECT_ID DATABASE INTENDED_STATE CONNECT_STRING ENABLED ROLE RECEIVE_FROM SHIP_TO FSFOVALIDITY STATUS ——— ————– —————– —————————- ——- ——– ———— ————– ———— ——- 16842752 toolcdb1_site1 READ-WRITE-XPTON newbox01:1521/TOOLCDB1_SITE1 YES…