Hello. Can’t figure out why the table is not being imported into phpmyadmin.
Structure:
Products table
Category table
I’m trying to import data from an xml dump of another table (it is identical with this one), but an error comes out
All categories with the same ID are in the database. Why can’t he tie them?
Issue resolved
Answer 1, authority 100%
The server will not invent anything. If he says that there are no corresponding records in the parent table, then they really do not exist. Complete your request
SELECT child.reference_field
FROM child
LEFT JOIN parent ON child.reference_field = parent.reference_field
WHERE parent.reference_field IS NULL
and see which values are missing.
PS. If you have a child table in XML, it’s better to import it into an unrelated temporary or static one, and then see what records the problem is with.