Jump to content
Software FX Community

MDX Query not displaying graph?


User (Legacy)

Recommended Posts

Hi,

I am trying to work out an example like this, but the graph does not

display any data.

Any help would be much appreciated

string myConnectionString;

string mySelectQuery;

DataSet dsSales = new DataSet();

OleDbDataAdapter adapter = new OleDbDataAdapter();

OleDbConnection myConnection = new

OleDbConnection();

myConnectionString="Provider=MSOLAP.2;Data

Source=localhost;Initial Catalog=FoodMart 2000;Client Cache Size=25;Auto

Synch Period=10000";

mySelectQuery = "select {[Measures].[unit Sales]} on

columns,order(except([Promotion Media].[Media Type].members,{[Promotion

Media].[Media Type].[No Media]}),[Measures].[unit Sales],DESC) on rows from

Sales";

myConnection = new

OleDbConnection(myConnectionString);

dsSales = new DataSet("Sales");

adapter = new System.Data.OleDb.OleDbDataAdapter();

adapter.SelectCommand = new

System.Data.OleDb.OleDbCommand(mySelectQuery, myConnection);

adapter.Fill(dsSales);

chart1.DataSourceSettings.DataSource =

dsSales.Tables[0];

Many Thanks

Prasad

Link to comment
Share on other sites

The Chart FX core can't read from an OLAP datasource. You will need to use 

the Chart FX OLAP extension, which can read OLAP data through ADOMD or XMLA.

For further details or to download a trial of this product, please visit

www.softwarefx.com\OLAP.

---

IG

Software FX

"Prasad" <prasad.maddukuri@company-net.com> wrote in message

news:eLu0UxruFHA.1768@webserver3.softwarefx.com...

> Hi,

>

> I am trying to work out an example like this, but the graph does not

> display any data.

>

> Any help would be much appreciated

>

> string myConnectionString;

>

> string mySelectQuery;

>

> DataSet dsSales = new DataSet();

>

> OleDbDataAdapter adapter = new OleDbDataAdapter();

>

> OleDbConnection myConnection = new

> OleDbConnection();

>

> myConnectionString="Provider=MSOLAP.2;Data

> Source=localhost;Initial Catalog=FoodMart 2000;Client Cache Size=25;Auto

> Synch Period=10000";

>

> mySelectQuery = "select {[Measures].[unit Sales]} on

> columns,order(except([Promotion Media].[Media Type].members,{[Promotion

> Media].[Media Type].[No Media]}),[Measures].[unit Sales],DESC) on rows

> from Sales";

>

> myConnection = new

> OleDbConnection(myConnectionString);

>

> dsSales = new DataSet("Sales");

>

> adapter = new System.Data.OleDb.OleDbDataAdapter();

>

> adapter.SelectCommand = new

> System.Data.OleDb.OleDbCommand(mySelectQuery, myConnection);

>

> adapter.Fill(dsSales);

>

> chart1.DataSourceSettings.DataSource =

> dsSales.Tables[0];

>

> Many Thanks

>

> Prasad

>

>

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...