Jump to content

Help with LEFT JOIN - Returning NULL for Results of one Table


Recommended Posts

Hello,

 

Im trying to use a LEFT Join on 2 tables: One is Affiliate Feed and the other is Price Feed. AffiliateFeed contains a list of items for sale. the id for each product is stored in the ID column. Mind that there is no Primary Key on this table since this table is imported from a feed daily to mysql server so.

 

The PriceFeed table contains 3 fields: EVENT_ID, MAXIMUM and MINIMUM. These are used to store the id of the product, its highest and lower price. This table also does not have a primary key.

 

This is the query Im using:

 

SELECT *

FROM AffiliateFeed

LEFT JOIN PriceFeed ON AffiliateFeed.ID = PriceFeed.EVENT_ID

WHERE GENREGRANDPARENT = 'DELL COMPUTERS'

 

The query returns all fields from AffiliateFeed and its data, but for the 3 fields from PriceFeed, EVENT_ID, MAXIMUM and MINIMUM showed as NULL (Im using PHPAdmin for this query). All data for these rows are NULL.

 

What can I do to fix???

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.