[PHP-DB] finder

2009-07-15 Thread Emiliano Boragina
Hello… I must to do a finder with 10 posibilities. This 10 can be full or empty. (sorry... I just ask this but I’m not understand yet) I know how to do a finder about any field, but this is my first time with one like this where the user can find a “house” in a “zone” or find anything in

Re: [PHP-DB] finder

2009-07-15 Thread Dan Shirah
Hello… I must to do a finder with 10 posibilities. This 10 can be full or empty. (sorry... I just ask this but I’m not understand yet) I know how to do a finder about any field, but this is my first time with one like this where the user can find a “house” in a “zone” or find anything

RE: [PHP-DB] finder

2009-07-15 Thread Emiliano Boragina
But with that it doesnt difference between full and empty field… If the user want search on two posibilities on ten... + _ // Emiliano Boragina _ // Diseño Comunicación // +

Re: [PHP-DB] finder

2009-07-15 Thread Dan Shirah
But with that it doesnt difference between full and empty field… If the user want search on two posibilities on ten... Maybe I'm not understanding what you're asking... Or maybe you don't understand the query... Say your form has 10 checkboxes. If the users picks 3 out of ten boxes and

[PHP-DB] general theory behind 'primary_key' 'auto_increment' flags, and ON DUPLICATE KEY UPDATE ?

2009-07-15 Thread Govinda
Reading docs.. I want to be sure of things... have your verification of my understanding(s)- Does setting a mysql db column (say myPrimarykeyID) with the 'primary_key' 'auto_increment' flags totally negate the logic for ever having to use ON DUPLICATE KEY UPDATE in an INSERT? Or is it

Re: [PHP-DB] general theory behind 'primary_key' 'auto_increment' flags, and ON DUPLICATE KEY UPDATE ?

2009-07-15 Thread Bastien Koert
On Wed, Jul 15, 2009 at 9:21 AM, Govindagovinda.webdnat...@gmail.com wrote: Reading docs..  I want to be sure of things...  have your verification of my understanding(s)- Does setting a mysql db column (say myPrimarykeyID) with the 'primary_key' 'auto_increment' flags totally negate the

[PHP-DB] Changing part of a query before displaying it

2009-07-15 Thread Don Collier
I am quite new at this so please bare with me. I am getting a several rows of data from a database to display in a table. One of the fields is in a format that I want to change before putting it in the table. The field is time in seconds, but I want it to be displayed in minutes instead.

Re: [PHP-DB] Changing part of a query before displaying it

2009-07-15 Thread Patrick Price
I believe your best bet is to change how you are iterating through the $row data. Since there are only 6 columns of data, I think the simplest solution is to remove the foreach() and handle each column's data independently, ie: while($row = mysql_fetch_row($result10)) { print ' tr

Re: [PHP-DB] Changing part of a query before displaying it

2009-07-15 Thread Don Collier
Would that work for multiple rows though? This is getting a varying number of rows. Patrick Price wrote: I believe your best bet is to change how you are iterating through the $row data. Since there are only 6 columns of data, I think the simplest solution is to remove the foreach() and

Re: [PHP-DB] Changing part of a query before displaying it

2009-07-15 Thread Patrick Price
Yes, the while loop will retrieve all the rows from the database. The foreach loop you had been using was retrieving all the data from each row. The only appreciable difference between your code and mine is in the circumstance, if you added more columns to the database, you would need to add more

Re: [PHP-DB] general theory behind 'primary_key' 'auto_increment' flags, and ON DUPLICATE KEY UPDATE ?

2009-07-15 Thread Govinda
On Jul 15, 2009, at 7:37 AM, Bastien Koert wrote: On Wed, Jul 15, 2009 at 9:21 AM, Govindagovinda.webdnat...@gmail.com wrote: Reading docs.. I want to be sure of things... have your verification of my understanding(s)- Does setting a mysql db column (say myPrimarykeyID) with the

Re: [PHP-DB] general theory behind 'primary_key' 'auto_increment' flags, and ON DUPLICATE KEY UPDATE ?

2009-07-15 Thread Bastien Koert
On Wed, Jul 15, 2009 at 4:40 PM, Govindagovinda.webdnat...@gmail.com wrote: On Jul 15, 2009, at 7:37 AM, Bastien Koert wrote: On Wed, Jul 15, 2009 at 9:21 AM, Govindagovinda.webdnat...@gmail.com wrote: Reading docs..  I want to be sure of things...  have your verification of my