Re: Re: NULLS vs Empty result in PHP

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



>
> using empty() is ´the right way to check a var for NULL or ""
>
> however, it also depends what MySQL has got as setuo definition for empty
> fields. on textfields u can define an epmty string as default.
>
> So say these are the first three results of my query:

"some text" //The column actually has data
"              " //The column contains a series of spaces
"NULL"       //The column contains a NULL value

As long as I trim() the result, if (!empty()) would skip any results where
the column contains "              " OR "NULL", correct?

[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux