[PHP-DB] PHP/DB speed

2003-12-21 Thread Robin Kopetzky
Good afternoon! I am writing a project and have a speed concern... The code I am using is thus and is retrieving around 2,500 records: $result = mysql_query($sql) while ($row = mysql_fetch_array($result)) { build stmt } Is

Re: [PHP-DB] PHP/DB speed

2003-12-21 Thread John W. Holmes
Robin Kopetzky wrote: Good afternoon! I am writing a project and have a speed concern... The code I am using is thus and is retrieving around 2,500 records: $result = mysql_query($sql) while ($row = mysql_fetch_array($result)) { build stmt }

[PHP-DB] Re: php mail() question

2003-12-21 Thread Manuel Lemos
Hello, On 12/18/2003 10:44 AM, Jerry wrote: How do I list the headers that are ouputed in the page into the text area also? You just need to call the RetrieveMessage function that returns the headers of each message and then look for the To: header. -- Regards, Manuel Lemos Free ready to use OO

Re: [PHP-DB] Reading emails with PHP

2003-12-21 Thread Manuel Lemos
Hello, On 12/19/2003 09:54 AM, David T-G wrote: OK, so on to the script. Just as PHP has classes, perl has modules which implement object code. Just as PHP has PEAR (I think; I'm still getting to know it), perl has CPAN, the Comprehensive Perl Archive Network. One advantage of perl's maturity i

Re: [PHP-DB] PHP/DB speed

2003-12-21 Thread Richard Davey
Hello Robin, Sunday, December 21, 2003, 10:15:35 PM, you wrote: RK> The code I am using is thus and is retrieving around 2,500 records: RK> $result = mysql_query($sql) RK> while ($row = mysql_fetch_array($result)) RK> { RK> build stmt RK> } You're building a sel

[PHP-DB] COUNT() returns 1, but should be 0

2003-12-21 Thread Lew Mark-Andrews
Hi all, I'm baffled by this. I've put together a rather simple newsletter + greeting card app for a company to send their clients personalized corporate e-mails each containing the URL link to the greeting card page. When the user successfully visits the view card page, my code writes the visit da

Re: [PHP-DB] PHP/DB speed

2003-12-21 Thread Miles Thompson
At 03:15 PM 12/21/2003 -0700, Robin Kopetzky wrote: Good afternoon! I am writing a project and have a speed concern... The code I am using is thus and is retrieving around 2,500 records: $result = mysql_query($sql) while ($row = mysql_fetch_array($result))

Re: [PHP-DB] COUNT() returns 1, but should be 0

2003-12-21 Thread Tobey Wheelock
On Mon, Dec 22, 2003 at 11:43:35AM +0900, Lew Mark-Andrews wrote: > Table structure for cardlist: > `visitdate` datetime default NULL, > $sql = "SELECT COUNT(visitdate) FROM cardlist GROUP BY visitdate"; > $visitcount = mysql_num_rows($query); > echo "Total number of visits: $visitcount"; // <

Re: [PHP-DB] COUNT() returns 1, but should be 0

2003-12-21 Thread John W. Holmes
Lew Mark-Andrews wrote: I get a count of 1 for the number of visits ($visitcount) using my following code. It should be 0. --- code in check_visits.php $sql = "SELECT COUNT(visitdate) FROM cardlist GROUP BY visitdate"; $query = mysql_query($sql) or die(" Cannot query the database

Re: [PHP-DB] COUNT() returns 1, but should be 0

2003-12-21 Thread Lew Mark-Andrews
John, >That's because you're displaying how many "rows" were returned from the >query, not the value that COUNT() returns. A query with COUNT() is >always going to return at least one row. > >$visitcount = mysql_result($query,0); Yes, that was it! Thank you so much. Lew -- PHP Database Mailing

[PHP-DB] Keeping the mailing list sain

2003-12-21 Thread Gavin Amm
Hi guys, So that I don't drive members of the mailing list insane: In Outlook XP (2002), I want to enable the "Out of office" feature; what I don't want to do is have it reply to every message posted to the PHP mailing list. Does anyone know how to create a rule, to do this? I really don't want