add header for stderr
use same format of exception message
add isEmpty() to verify whether data is empty or not