How would a date command output null/nothing when the variable supplied has no/null value. I know if else statement can do this, but I kinda think it's not the proper way. Is there a decent command or alterations to the date command to do this?
E.g.
myDay=""
bDay=`date -d "$myDay"`
echo "$bDay" // this should have no output