Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
using (var conn = new AdomdConnection(connectionString))
{
conn.Open();
var commandText = @"SELECT
{
[Measures].[Gains Period],
[Measures].[Gains YTD],
[Measures].[Amount]
} ON COLUMNS,
[Valuation Dates Accumulated].[Hierarchy].[Year].Members ON ROWS
FROM Accumulated
Where ({ @PortfolioId })";
var data = conn.Query<MyResultDTO>(commandText,
new AdomdParameterMultipleValues<int>()
{
ParameterName = "@PortfolioId",
MemberName = "[Portfolios].[Port Code]",
Values = new List<int>() { 282, 185 }
}
);
conn.Close();
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.