以前に結合されたテーブルのデータから取得したテーブルに結合を作成する方法はありますか? たとえば、既存のテーブル名、それらのテーブルの表示フィールド、およびそれらのテーブルのメイン ID フィールドを含むオブジェクト テーブルがあります。オブジェクト テーブルだけでなく、オブジェクト テーブルで指定されたテーブルにも参加したいと考えています。
select T.field1,T.field2,T.field3,O.DisplayName
from tableT as T
inner join objects as O on T.SystemObjectID = O.SystemObjectID
inner join O.TableName as X on X.O.ID = T.SystemObjectRecordID
上記のスクリプトが正しくないことは理解しています。しかし、このタスクを達成するための最も簡単で効率的な方法は何でしょうか? 私が何を求めているのかが明確であることを願っています...
事前に助けてくれてありがとう。