jatar_k

msg:1578340 | 6:35 pm on Oct 18, 2005 (gmt 0) |
have you tried deleting the original and leaving the dupe in case there is some corruption in the row? if you add another record does it still do it?
|
feralo

msg:1578341 | 6:53 pm on Oct 18, 2005 (gmt 0) |
i just inserted a new record with unique information and now both (of the duplicate) records show up, but not the new one...
|
jatar_k

msg:1578342 | 7:02 pm on Oct 18, 2005 (gmt 0) |
are you using a limit on your query that might be offset by 1? are you sure it isn't a php loop counter issue?
|
feralo

msg:1578343 | 7:06 pm on Oct 18, 2005 (gmt 0) |
i have (this is not the exact code only an idea of it) "SELECT * FROM table ORDER BY `date` DESC"; $r = mysql_query($q, $db) and the only loop that i do is: while ($result = mysql_fetch_object($r)) {print...}
|
jatar_k

msg:1578344 | 7:29 pm on Oct 18, 2005 (gmt 0) |
do you do anything else at all with $r bfore your mysql_fetch_object? anything that might offset the internal pointer?
|
feralo

msg:1578345 | 7:35 pm on Oct 18, 2005 (gmt 0) |
i assigned it as so $r = mysql_query($q, $db) where $q = the MySQL: Select statement... Thank you for your patience, and tolerace (since this seems to be more PHP based than MySQL related...)
|
coopster

msg:1578346 | 9:05 pm on Oct 18, 2005 (gmt 0) |
The quickest way to determine where the problem lies -- MySQL or PHP -- would be to run the query statement from a command line. Take a look at the result set and see if all the rows you expect to see are there. To get the same exact query statement that is being processed by your PHP script, dump the statement to your browser, copy and paste it to the command line, and check the results.
$q = "SELECT * FROM table ORDER BY `date` DESC"; exit("$q"); // script stops here, copy the statement from the browser $r = mysql_query($q, $db); while ($result = mysql_fetch_object($r)) { // print ... } On a side note, although MySQL allows you to use 'date' as a column name, I still try to keep away from using reserved words.
|
|