I have a table of addresses in a database containing USA zip codes
the columns in table are called zip5 and zip4
I want to combine these zip codes with - in between that
I am currently using mysql the query i am using is
select zip5,zip4, concat(zip5,'-',zip4) zip from address limit 500;
now there are certain occasions where zip4 column is null but there is data in zip5 column
in this situation new concatenated column call zip becomes null.
I dont want this to happen. if zip4 does not have data at least it should show data from zip5 with no - in between that.