Having the following MySQL tables:
products: id, name, description
categories: id, name, description
prodcat: id_product, id_catategory
How can I select all the "products"
fields and all the
"categories"
fields of the products that have not been associated to a category?
How can I associate products to a category ? (PHPMyAdmin – SQL)
Product:
ID Name Description
1- Nike_Pegasus_Zoom – running_shoes
2- Adidas Jacket – jacket
3 – Adidas Telstar – ball
Categories:
ID Name Description
1 Shoes
2 Clothes
Must to associate the products to a category!
2
Answers
i didn’t understand well your question but I guess you want to have all
products
that don’t have acategory
associatedMaybe just a join would be enough…