implemented SQLTableElement::prepareJoin() that mainly gets the ItemDataIndex instance.