Updated show command to return a status code

This pull request updates the show command to return an integer status code. This also fixes #1023.

In case there are no results we return the status code 1 as error.

If desired we can choose a different status code to be more precise.