So, I'm new to rdlc (and reporting in general actually). I have a table that has a one-to-many relationship with another table, and I'm trying to represent them in an rdlc report as multiple tables for each item.
Note: The tables are originally created using Entity Framework code-first.
Here are the two tables (and the parent one):
Now, normally if I only have the [Quotation]
and some [QuotationItem]
s, I'd just add the info from the [Quotation]
on the top of the report, and the info from each [QuotationItem]
would be represented in a row inside a table (Tablix).
The problem is: Each [QuotationItem]
also has many of [QuotationItemQuantity]
(currently three), and they need to be represented too.
So, my report should look something like this:
But I'm stuck on how to display multiple tables (or a list and tables) for each item (QuotationItem). I tried nested tables and tables inside a list, but this doesn't seem to be allowed (I get a "Detail members can only contain static inner members" error).
I read about sub-reports and I think this might be the way to go, but I'm not sure how to use sub-reports in this case, or if this is actually the right approach.
Note: As mentioned above, each QuotationItem
currently has 3 quantities, but that might be changed in the future, so would be great if the columns can be dynamic, however, this isn't a requirement at this point.
Any suggestions?