Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
以下は、Report Builder データセットに入力したクエリです。ただし、最初の Select * from #Temp の変数のみが表示され、2 番目の select ステートメントの変数は表示されません。
Reporting Services は、DataSet に入力するために 1 つの結果セットのみを想定し、処理することしかできません。クエリによって返された最初の結果セットを受け入れ、それ以外はすべて破棄します。
私が考えることができるいくつかのオプション:
個別のクエリに 2 つの DataSet を使用します。
1 つの詳細 DataSet を使用し、必要な集計をレポート レベルで適用します。
aUNION ALLまたは同様のものを使用して、クエリ レベルで 2 つの結果セットを結合します。
UNION ALL