Find out your SLES version and service pack level from command line

I recently needed to find out the version of SLES that was running using the command line. This did the trick: