开发者

SQL Server Business Intelligence Studio: Discontinuous Line Chart

开发者 https://www.devze.com 2023-02-13 10:57 出处:网络
I have a report in SQL Server Business Intelligence Studio that is a .rdl file(Report Definition/Report Designer). Currently, the report graphs a line chart given the a LOAN_AMOUNT(Y-AXIS) for a given

I have a report in SQL Server Business Intelligence Studio that is a .rdl file(Report Definition/Report Designer). Currently, the report graphs a line chart given the a LOAN_AMOUNT(Y-AXIS) for a given Day of the Month (X-AXIS). Everyday of the month is not represented as data being retrieved开发者_C百科 from the database. As a result, certain parts of a line may be discontinuous. How do I make this line continuous even if no data-points exist?


You should use a function like this:

http://www.sqlteam.com/forums/topic.asp?TOPIC_ID=61519

To generate all dates, even if they are not in the database and assign the loan amount to 0.

For instance, if in february (no leap year) and your database has values for feb 1, and feb 14 only then you should use the date function posted to get all dates and assign the value 0 to loan amount of all other dates. Only then should you use this as your datasource for your report (I assume you are using stored procedures and not a direct table).

0

精彩评论

暂无评论...
验证码 换一张
取 消