Answer the question
In order to leave comments, you need to log in
How to make a selection from a MySQL database?
There is a main table, 6911 records in it,
wrote the following SQL query:
select a.id as id, a.added_date, a.updated_date, a.codename, a.title, a.tech_title, a.category, f.name as family, d.name as developer, a.os, a.domain, a.FULL_URL, a.publicly_called, a.has_image, a.Available_for_PPC, a.PPC_Risk, a.Is_in_blogs, a.Publish_in_Blog, a.Publish_in_Feed, a.IS_IN_SOFT, a.Has_Tech_Info, u.nick as assigned_to, s.name as status, a.domain_popularity, a.adwords_activity, a.lp, a.seo, a.partners, a.Software_Scan, a.Software_Fix, a.tickets, a.Youtube_URL, a.SEVERITY, a.Image_URL
from artpost_table as a
join developer as d on a.developer = d.id
join family as f on a.family = f.id
join users as u on a.assigned_to = u.id
join status as s on a.status = s.id
SELECT * FROM `artpost_table` WHERE 1
SELECT a.id as id, a.added_date, a.updated_date, a.codename, a.title, a.tech_title, c.name as category, f.name as family, d.name as developer, a.os, a.domain, a.FULL_URL, a.publicly_called, a.has_image, a.Available_for_PPC, a.PPC_Risk, a.Is_in_blogs, a.Publish_in_Blog, a.Publish_in_Feed, a.IS_IN_SOFT, a.Has_Tech_Info, u.nick as assigned_to, s.name as status, a.domain_popularity, a.adwords_activity, a.lp, a.seo, a.partners, a.Software_Scan, a.Software_Fix, a.tickets, a.Youtube_URL, a.SEVERITY, a.Image_URL
FROM artpost_table as a
LEFT JOIN developer as d on a.developer = d.id
LEFT JOIN family as f on a.family = f.id
LEFT JOIN users as u on a.assigned_to = u.id
LEFT JOIN status as s on a.status = s.id
LEFT JOIN category as c on a.category = c.id
Answer the question
In order to leave comments, you need to log in
Instead of JOIN , write LEFT JOIN and there will be all records.
Not all fields are filled in / have a match in other tables. Therefore, only records with full matches are shown, of which there are 349.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question