So you're saying a page refresh in your browser doesn't cure the problem?
--
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Okay. I am pretty new to mysql so this may seem like a ridiculous
question to some people.
I am trying to use a LEFT JOIN query, but the results I am finding
unusual. For every record occurrence there is for the query, the
results are duplicated by that amount.
So if there are 3 records from the
Hey folks,
PostgreSQL Conference West is closing its CFP this week. Would love to
see some PHP talks there this year!
https://www.postgresqlconference.org/talk_types
Sincerely,
JD
--
Command Prompt, Inc. - http://www.commandprompt.com/
PostgreSQL Support, Training, Professional Services
On 9 August 2011 20:31, Chris Stinemetz chrisstinem...@gmail.com wrote:
Okay. I am pretty new to mysql so this may seem like a ridiculous
question to some people.
I am trying to use a LEFT JOIN query, but the results I am finding
unusual. For every record occurrence there is for the query,
Is users.user_id unique?
yes it is.
--
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
On 9 August 2011 20:49, Chris Stinemetz chrisstinem...@gmail.com wrote:
Is users.user_id unique?
yes it is.
What does your result look like? Hard to say what the problem is
without seeing the result.
--
hype
WWW: plphp.dk / plind.dk
LinkedIn: plind
BeWelcome/Couchsurfing: Fake51
Twitter:
What does your result look like? Hard to say what the problem is
without seeing the result.
I am echoing the query and printing the get array just for debugging
purposes, but below you can see how it is repeating its' self.
Thank you
Array
(
[id] = Bella Roe 4980 Roe Blvd
)
Bella
On 9 August 2011 21:23, Chris Stinemetz chrisstinem...@gmail.com wrote:
What does your result look like? Hard to say what the problem is
without seeing the result.
I am echoing the query and printing the get array just for debugging
purposes, but below you can see how it is
Okay. I just validated it is not in the left join query, but in my php. I
was able to build the correct relations.
Does anyone see any think in the php code below that may cause duplicate
table rows?
Thank you all.
?php
//store.php
include_once 'includes/connect.php';
include_once
You already have a foreign key, that is stores.store_by references
users.user_id. You might not have declared it (which is OK) but if that is the
key you want that is fine.
I suspect you are seeing an inadvertent Cartesian product. The way you have
written this query you will get one row
On Tue, Aug 9, 2011 at 2:55 PM, Frank Flynn fr...@declan.com wrote:
You already have a foreign key, that is stores.store_by references
users.user_id. You might not have declared it (which is OK) but if that is
the key you want that is fine.
I suspect you are seeing an inadvertent Cartesian
When I dump the query and run it in console I get the results I want. Not
sure what I am doing wrong.
Your php code had more than one query running (one inside the other).
It's the outer query that runs twice, not the inner one returning
double the results
--
hype
WWW: plphp.dk / plind.dk
Your php code had more than one query running (one inside the other).
It's the outer query that runs twice, not the inner one returning
double the results
Thanks Peter,
Do you have any suggestions on how to fix this?
Thank you,
Chris
--
PHP Database Mailing List (http://www.php.net/)
On 9 August 2011 22:25, Chris Stinemetz chrisstinem...@gmail.com wrote:
Your php code had more than one query running (one inside the other).
It's the outer query that runs twice, not the inner one returning
double the results
Thanks Peter,
Do you have any suggestions on how to fix this?
Yes, debug your code and figure out why it's looping twice instead.
For instance, try the other query in the mysql console.
Thank you! It was the first query. I put a LIMIT 1 on it and now it is
working correctly. I appreciate your help!
Thank you,
Chris
--
PHP Database Mailing List
On 9 August 2011 22:38, Chris Stinemetz chrisstinem...@gmail.com wrote:
Yes, debug your code and figure out why it's looping twice instead.
For instance, try the other query in the mysql console.
Thank you! It was the first query. I put a LIMIT 1 on it and now it is
working correctly. I
Jim Giner wrote:
So you're saying a page refresh in your browser doesn't cure the problem?
Hi, sorry for the delay.. Yes, page refresh/s is basically what I am
doing to get to the latest edits (by clicking in and out of the edit
area). Reloading the page one or more times works as well.
17 matches
Mail list logo