posted 17 years ago
Self join is simply a FK in a table referencing itself. Meaning I have a table that has a PK, and it has a FK field which points to the PK. Thinks like Employees is a good example. you can have a Manager field in Employee to represent who is that employees manager, But the manager himself is also an Employee with a record in the Employee table, so that sub-ordinate has the Manager's Employee id in its Employee record.
Inner Join is a query term. I have two tables, using an Inner Join I get back results where they join. So if I have a table that has a foreign key into the second table, then I get all the results where there is a record in the one table with a corresponding record in the other table through the foreign key. Which is opposite of the Outer Join Types, where you can still get records from the first table, even if there isn's a corresponding record in the other table. Meaning the one's table FK field is null, that record still can come back in the resultset.
Mark