My query is also an example ... and, regarding YOUR example, you took all records from table A and only the D002 record from table B. I really wouldn't know your real situation; if you need to join all records from one and another table, then use simply
SELECT * FROM a UNION SELECT * FROM b;
Or, if you have conditions to meet, include them into the WHERE clause(s).
In theory yes that would work, but I'm willing to bet dollars to donuts that his tables contain a couple more rows. So dual would literally give you those 3 rows, but I think he is looking more for a pattern to grab unrelated data from 2 tables.
But as others post, since little detail is given, its all just speculamation.