PHP to Excel, Quick Question
| From: | Jay Blanchard | Date: | Fri, 03 May 2002 17:27:26 +0000 |
| Subject: | PHP to Excel, Quick Question | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-95938@lists.php.net to get a copy of this message | ||
Again, thanks to folks on the list I learned the "stupid IE trick" for
opening an Excel worksheet in the browser from a PHP generated table. Here
is another quick question...in my DB query for the values I have
SUM(IF(If FOO is this, return this number, else return a blank)) that looks
like this really
SUM(IF(RecordID = '100101', 1, ''))
Which works correctly BUT, if the statement is false it does not show a
blank cell in the worksheet, but a "0" (zero).
I have tried
stuff, 1, '\'' (escape a tick which Excel normally uses to display numbers
as text)
stuff, 1, ' ' (a space)
stuff, 1, NULL (which still returns a zero)
stuff, 1, (which throws errors)
stuff, 1, '\"\"' (which still returns a zero)
stuff, 1, '\ ' (escape a space)
The worksheet still has zero values displayed, no matter what I do (except
for that which throws errors). Ideas?
TIA!
Jay