Hi
I have a SQLDatasource which uses a query to make a join across databases. The data returned is should be used to create the bar chart. However, no matter what I do, it fails to display anything.
As a check that the sqldatasource is fetching the data, I'm also binding it to radgrid on the page. The grid is working just fine and showing all the data. However the chart shows nothing.
The main parts from my page:-
<p> <asp:DropDownList ID="PocList" runat="server" AutoPostBack="True" DataSourceID="LinqDataSource1" DataTextField="outlet_name" DataValueField="outlet_id"></asp:DropDownList></p><p> <asp:DropDownList ID="MonthList" runat="server" AutoPostBack="true"> <asp:ListItem Value="1" Text="January"/> <asp:ListItem Value="2" Text="February"/> <asp:ListItem Value="3" Text="March"/> <asp:ListItem Value="4" Text="April"/> <asp:ListItem Value="5" Text="May"/> <asp:ListItem Value="6" Text="June"/> <asp:ListItem Value="7" Text="July"/> <asp:ListItem Value="8" Text="August"/> <asp:ListItem Value="9" Text="September"/> <asp:ListItem Value="10" Text="October"/> <asp:ListItem Value="11" Text="November"/> <asp:ListItem Value="12" Text="December"/> </asp:DropDownList></p><asp:LinqDataSource ID="LinqDataSource1" runat="server" ContextTypeName="WebApplication1.RewardsDataClassesDataContext" EntityTypeName="" OrderBy="outlet_name" Select="new (outlet_id, outlet_name)" TableName="outlet_accounts"></asp:LinqDataSource><telerik:RadHtmlChart ID="PocChart" runat="server" DataSourceID="SqlDataSource1" > <PlotArea> <Series> <telerik:ColumnSeries DataFieldY="totalValue"> <TooltipsAppearance Color="White" DataFormatString="${0}"></TooltipsAppearance> </telerik:ColumnSeries> </Series> <XAxis DataLabelsField="brandname"> <LabelsAppearance RotationAngle="75"/> <MajorGridLines Visible="false"/> <MinorGridLines Visible="false"/> </XAxis> <YAxis> <LabelsAppearance DataFormatString="${0}"></LabelsAppearance> <TitleAppearance Text="Total Points Value"></TitleAppearance> <MinorGridLines Visible="false"></MinorGridLines> </YAxis> </PlotArea></telerik:RadHtmlChart><telerik:RadGrid ID="RadGrid1" runat="server" DataSourceID="SqlDataSource1" GroupPanelPosition="Top"> <MasterTableView AutoGenerateColumns="False" DataSourceID="SqlDataSource1"> <Columns> <telerik:GridBoundColumn DataField="month" DataType="System.Int32" FilterControlAltText="Filter month column" HeaderText="month" SortExpression="month" UniqueName="month"> </telerik:GridBoundColumn> <telerik:GridBoundColumn DataField="brand_id" DataType="System.Int32" FilterControlAltText="Filter brand_id column" HeaderText="brand_id" SortExpression="brand_id" UniqueName="brand_id"> </telerik:GridBoundColumn> <telerik:GridBoundColumn DataField="brandname" FilterControlAltText="Filter brandname column" HeaderText="brandname" SortExpression="brandname" UniqueName="brandname"> </telerik:GridBoundColumn> <telerik:GridBoundColumn DataField="value" DataType="System.Int32" FilterControlAltText="Filter value column" HeaderText="value" ReadOnly="True" SortExpression="value" UniqueName="value"> </telerik:GridBoundColumn> </Columns> </MasterTableView></telerik:RadGrid><asp:SqlDataSource ID="SqlDataSource1" runat="server" ConnectionString="<%$ ConnectionStrings:Appreciation_WarehouseConnectionString %>" SelectCommand="SELECT omba.month, omba.brand_id, bd.brand_name AS brandname, SUM(omba.total_value) AS totalValue FROM outlet_month_brand_aggregation AS omba INNER JOIN appreciation_rewards.dbo.brand AS bd ON omba.brand_id = bd.brand_id WHERE (omba.outlet_id = @oid) AND (omba.month = @month) GROUP BY omba.brand_id, omba.month, bd.brand_name ORDER BY omba.month, brandname"> <SelectParameters> <asp:ControlParameter ControlID="PocList" DefaultValue="6782" Name="oid" PropertyName="SelectedValue" Type="Int32" /> <asp:ControlParameter ControlID="MonthList" DefaultValue="1" Name="month" PropertyName="SelectedValue" Type="Int32" /> </SelectParameters></asp:SqlDataSource>