Export database in one file with every dataset existing
My guess is you need to specify the type of join.  You really want a "full outer join" which will not exclude records.  A select where you join by keys will default to an inner join.

See https://stackoverflow.com/a/6188334/259538