私は次のように3つのテーブルを持っています
Table #1 has column UserId and UserName
Table #2 has column MenuId and MenuName
Table #3 has column MappingId, UserId, MenuId
(表#3の列では、UserIdとMenuIdは、それぞれ表#1のuserIdと表#2のMenuIdと外部キーの関係にあります。)
次のようなselectステートメントが必要です
UserName, MenuName, AllowedDisallowedFlag
Where
UserName is Names of User From Table #1
MenuName is Names of Menu from Table #2
UserNameとAllowedDisallowedFlag
MenuNameの組み合わせが表3に存在する場合はtrueになり、存在しない場合はfalseになります。
カーソルやループを使用せずにこれを実現する方法はありますか?