As ubuntu droped the oracle jdk support from 12.04 fully, you may face some performance and stability problem with the open jdk. Here is the simple 3 line tricks to get the oracle/sun jdk in 12.04
sudo add-apt-repository ppa:flexiondotorg/java
sudo apt-get update
sudo apt-get install sun-java6-jdk sun-java6-plugin
You may see few key warning. Just ignore those, it’s the PPA’s small issue. but the jdk will work great.
Please let us know if you face any problem
You may also like to read: