I am new to java and I installed JDk 7 using
sudo apt-get install openjdk-7-jre
But when I do java -version I get this
java version "1.6.0_26" Java(TM) SE Runtime Environment (build 1.6.0_26-b03) Java HotSpot(TM) Server VM (build 20.1-b02, mixed mode)
How do I set it to 1.7 and also how do I set my compiler to 1.7 in eclipse?