Re: [PHP-DB] PHP and MySQL design question

2007-11-01 Thread Chris
Roberto Mansfield wrote: It shouldn't matter what order the columns are referenced. Mysql is smart enough to optimize the query based on the available indexes. In some cases yes but as with anything there are exceptions :) mysql (and every other db) gets it wrong sometimes. In fact, it shoul

Re: [PHP-DB] PHP/MySQL - Matrix

2007-11-01 Thread Chris
Eduardo Vizcarra wrote: Hi Chris How do I save the matrix in the session ? Actually, my first question is, what do you mean by a session ? http://www.php.net/session Look under the examples. -- Postgresql & php tutorials http://www.designmagick.com/ -- PHP Database Mailing List (http://www

Re: [PHP-DB] PHP/MySQL - Matrix

2007-11-01 Thread Eduardo Vizcarra
Hi Chris How do I save the matrix in the session ? Actually, my first question is, what do you mean by a session ? Regards Eduardo "Chris" <[EMAIL PROTECTED]> escribió en el mensaje news:[EMAIL PROTECTED] > >> When I get all the records from the photos table, I am using a web page >> to displ

Re: [PHP-DB] PHP/MySQL - Matrix

2007-11-01 Thread Chris
When I get all the records from the photos table, I am using a web page to display only the first record, then, if the user hits a next link then the user should be able to see the next record (next picture) and so on, I do not want to do a select every time the user hits next or back to get t

[PHP-DB] PHP/MySQL - Matrix

2007-11-01 Thread Eduardo Vizcarra
Hi, I am developing a web site where I have a photos table, several records from the photos table can be linked to a different table referentially. When I do a SELECT to all photos records I can get multiple records, I do not have any problems doing this, the problem is all the procedure after

RE: [PHP-DB] Phpmailer sending duplicate messages...

2007-11-01 Thread Instruct ICC
> Stut and Instruct > > Just found this which clears the email after each loop. > > $mail->ClearAddresses(); > > Thanks for you input. Good find. Now the list can benefit. _ Climb to the top of the charts!  Play Star Shuffle:  t

[PHP-DB] RE: inserting history after sending phpmailer message

2007-11-01 Thread Instruct ICC
> So the following code is now sending one email to each recipient but now > that'd I've added the insert statement at the bottom it only sends one email > and one history and I get the following error message" > > Warning: mysqli_fetch_assoc() expects parameter 1 to be mysqli_result, > boolean g

Re: [PHP-DB] PHP cannot access mySQL

2007-11-01 Thread Chris
Nhan wrote: Hi, I have IIS 5.1 with PHP 5 and MySQL 4.1 With a client tool (such as MySQL Front) I can access MySQL. But my PHP page cannot, with the same username and passord. Why? What can I do? What is the error message? -- Postgresql & php tutorials http://www.designmagick.com/ -- PHP

Re: [PHP-DB] Re: backup of database record before update

2007-11-01 Thread hochprior
"Neil Smith [MVP, Digital media]" wrote: At 09:46 01/11/2007, you wrote: Message-ID: <[EMAIL PROTECTED]> Date: Thu, 1 Nov 2007 10:45:57 +0100 "Leo G. Divinagracia III" wrote: Stephen Sunderlin wrote: Neil, Have you had success with triggers. I couldn't get one to work and then saw discussi

Re: [PHP-DB] Re: backup of database record before update

2007-11-01 Thread Neil Smith [MVP, Digital media]
At 09:46 01/11/2007, you wrote: Message-ID: <[EMAIL PROTECTED]> Date: Thu, 1 Nov 2007 10:45:57 +0100 "Leo G. Divinagracia III" wrote: Stephen Sunderlin wrote: Neil, Have you had success with triggers. I couldn't get one to work and then saw discussion ... ...snip... ... on a 5.0.20nt box.

RE: [PHP-DB] Phpmailer sending duplicate messages...

2007-11-01 Thread Instruct ICC
> You're re-using the same message each time around the loop. Each time > you call AddAddress you're, erm, adding another address. You either need > to reset the recipients or reset the message each time round the loop > (I'm not familiar with Phpmailer so I have no idea how to do this). > > -

Re: [PHP-DB] Phpmailer sending duplicate messages...

2007-11-01 Thread Stut
Stephen Sunderlin wrote: It seems to be ccing each email to everyone and I'd like it to only include one email address with each email. I've tested in on three of my personal emails and I see to get six messages in my inbox. I'm also sending about 4000 emails and would like some pointers to avo

RE: [PHP-DB] Phpmailer sending duplicate messages...

2007-11-01 Thread Instruct ICC
> while($row = mysqli_fetch_assoc($result)) > { > extract($row); > > $mail->IsSMTP(); > $mail->Host = "host.com"; > $mail->From = "[EMAIL PROTECTED]"; > > $mail->From = "[EMAIL PROTECTED]"; > $mail->FromName = "Company"; > $mail->AddAddress("$email", "$Contact"); > >

[PHP-DB] PHP 5.2 and MySQL on IIS

2007-11-01 Thread Bruce Cowin
I originally sent this message to the general list, but maybe it's more appropriate here... I have just installed PHP 5.2.4 on Windows 2003 machine running IIS. Everything is fine except when I try to enable the MySQL extension (either php_mysqli.dll or php_mysql.dll), when I do a php_info(), at

[PHP-DB] Phpmailer sending duplicate messages...

2007-11-01 Thread Stephen Sunderlin
It seems to be ccing each email to everyone and I'd like it to only include one email address with each email. I've tested in on three of my personal emails and I see to get six messages in my inbox. I'm also sending about 4000 emails and would like some pointers to avoid time out errors. Finall

[PHP-DB] PHP cannot access mySQL

2007-11-01 Thread Nhan
Hi, I have IIS 5.1 with PHP 5 and MySQL 4.1 With a client tool (such as MySQL Front) I can access MySQL. But my PHP page cannot, with the same username and passord. Why? What can I do? Thanks Nhan -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsu

Re: [PHP-DB] parameters not working under PDO

2007-11-01 Thread Chris Curvey
Ah, but the *contents* of the array are not what I thought they were...there was a leading space in "nj". Which brings me to something I've been wondering...is there a way to get the statement object to tell me EXACTLY what was sent to the database engine? Chris Curvey wrote: good thing to

Re: [PHP-DB] Re: backup of database record before update

2007-11-01 Thread hochprior
"Leo G. Divinagracia III" wrote: Stephen Sunderlin wrote: Neil, Have you had success with triggers. I couldn't get one to work and then saw discussion on the board here that MYSQL triggers were not so reliable and still somewhat problematic so I archive through the application. Just curious.