Select all cells that are not empty MYSQL
I have a table where I need to find wheter the cell is empty or not. I
don't have the specific column name so I need to display all of the cells
that are not empty. (PHP solution would fit too.) Thank you!
Here is my piece of code:
$result1 = mysql_query("SELECT * FROM `FACILITIES` WHERE `room_id` =
'{$row['id']}'");
while($row1 = mysql_fetch_assoc($result1)) {
if(empty($row[''])) { //What should I fill in in the $row
variable?
alert("Empty");
}
}
I have tried doing in in PHP, but a MYSQL solution would fit too.
No comments:
Post a Comment