There are several questions, so I will try to answer one by one.
ORA-02291: integrity constraint violated - parent key not found
There is nothing to guess, because, as you know, you do not have a parent record for table X. By the way, you can also use the CONSTRAINTS=N flag, because you already have db, as you said.
"I want to import all tables related to X. How can I achieve this?"
Well, there is no option but to find all the dependencies manually (or use user_cons_columns , user_constraints , etc. data dictionary tables for searching) and import these tables. Think about it if you do not. You will violate data integrity. If you still need this data in table X with no dependencies, disable the restrictions and then import. But you wonโt be able to turn on your restriction again, and I donโt know what you want to do with the broken data.
"I also need to know the order of these tables in order to know to import first."
Disable restrictions before importing, and then enable them after importing. In this case, you do not need to worry about the order.
source share