Jump to content


Photo

Ignoring Empty Entries


  • Please log in to reply
2 replies to this topic

#1 willdikuloz

willdikuloz
  • Members
  • PipPip
  • Member
  • 13 posts

Posted 15 June 2006 - 09:33 PM

Is there a way to SELECT only entries that actually have something in them and ignore the empty ones?

#2 Barand

Barand
  • Moderators
  • Sen . ( ile || sei )
  • 18,015 posts

Posted 15 June 2006 - 09:40 PM

[!--sql--][div class=\'sqltop\']SQL[/div][div class=\'sqlmain\'][!--sql1--][span style=\'color:blue;font-weight:bold\']SELECT[/span] colname FROM tablename WHERE colname IS NOT NULL [!--sql2--][/div][!--sql3--]
If you are still using mysql_ functions, STOP! Use mysqli_ or PDO. The longer you leave it the more you will have to rewrite.

Donations gratefully received






moon.png

|baaGrid| easy data tables - and more
|baaChart| easy line, column and pie charts

#3 willdikuloz

willdikuloz
  • Members
  • PipPip
  • Member
  • 13 posts

Posted 15 June 2006 - 10:23 PM

Doesn't work, I heard that empty values is different from null.




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users