franco Posted April 25, 2006 Share Posted April 25, 2006 I am building an html table that lists about 50 records worth of date from a database. The database has a lot of blank (null) fields. In my html table, I would like to make all of those fields show 0 instead of just being blank. What would be the easiest way to do this? Link to comment https://forums.phpfreaks.com/topic/8320-zero-in-place-of-null/ Share on other sites More sharing options...
fenway Posted April 25, 2006 Share Posted April 25, 2006 Well, you can either handle this in MySQL with IFNULL(), but this won't be clean if you have many NULL-able columns. Otherwise, do it in PHP on the way out. Link to comment https://forums.phpfreaks.com/topic/8320-zero-in-place-of-null/#findComment-30654 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.