AEM Blue

We recently upgraded one of our environments from Oracle 12.1.0.2 to 12.2.0.1 and moved from a non-CDB architecture to a CDB/PDB setup. 

In this blog series, I will go through the full process of a database version upgrade and an architecture update. I will also discuss lessons learned and a few tips I gathered during this endeavor. 

History Command

One of the new features that I looked most forward to with 12.2 is also one of the most basic: a listing of prior SQL commands that have been run. The history command is like the Linux history command. Here is an example of this:

This feature can be very helpful when troubleshooting or if running a process that requires the same commands repeatedly. Any of the previously run commands can be called back and executed again by using the following syntax, “history XX run”:

There are a few limitations associated with this command. The first limitation is that this is a SQLPLUS specific update, so if you use a different tool (like Toad) to connect to the database, this will not work. Additionally, in a departure from the Linux history command, this is a session-specific feature. You will only see a history of commands that you have entered since you have logged in.

Since this is a session-specific feature, you must enable the history option every time you log in with this command:

This can be inconvenient since you could easily forget to turn the setting on before each session. Luckily, there is a solution to this problem. You can have the history setting on by default whenever you log in by modifying the glogin.sql file. This file is located at $ORACLE_HOME/sqlplus/admin. All that’s required is adding the “set history on” command to the file like this:

The history command is a helpful new feature that can be a real time saver. Don’t forget that this is only a SQLPLUS feature and that it only saves commands that you have entered during your current session. Also, remember that if you want to use this feature regularly, you can set the history option to be on by default by modifying the glogin.sql file.

Want more?

Make sure to stay tuned for more tips and tricks for your own Oracle database upgrade efforts. To get notified when we release more of these tips, please visit our homepage and sign up for our updates on the right-hand side of the page. 

See [Part 2] PDB Save State: Tips and Tricks for Your 12.2 Oracle Database Upgrade.

RECOMMENDED BLOG POSTS

Installing Oracle Access Management 12.2.1.4

Oracle Access Management (OAM) is Oracle’s solution for user management. The software is part of the Fusion Middleware Infrastructure family and can be integrated with both Oracle and non-Oracle software. OAM provides an enterprise-level platform that delivers user authentication and single sign-on (SSO) capabilities in a simple web-based console. Access Manager SSO allows for entities to access multiple applications after authentication and reduces the need for multiple logins. 

5 Lessons for Finding the Right Test Automation Software

This is the second blog post in a two-part series examining test automation software. This blog post focuses on lessons learned for finding the right software product for your organization. We recommend you also read our first post, which is dedicated to understanding the process for moving from manual to automated testing.

5 Keys to Successful Test Automation

This blog post is the first in a two-part series on website testing automation that can help your organization better understand how to maximize the effectiveness of your tests and find the right tools to meet your needs. Below we offer insights that can help your organization improve its testing automation process. Our follow-on blog post will help your organization understand the different software tools available to begin automating your tests.