Issue Fixed for colspan

Added logic so that if a data item doesnt exist under a column it doesnt
get added.