I am a new comer in data mining, so I have some question that: Which
Microsoft? OLE DB Providers supported in Data Mining Services 2005? Is
MSDMine provider supported in Data mining Service 2005? Why no mining
model is created (althought there is no exception) when I run the program
like that: (I use C# in Microsoft Visual Studio 2005). I look forward
to hearing from you soon. Thanks and regards.
using System.Data.Oledb;
using System.Data;
............
string sConnect = "Provider =MSDMine;Data source = localhost;Initial
Catalog = Analysis Services Project1";
OleDbConnection cn = new OleDbConnection(sConnect);
OleDbCommand cmd = new OleDbCommand();
cmd.Connection = cn;
cmd.CommandText = "CREATE MINING MODEL [AnalyzeShipments]( "
+ " [Shipment Id] LONG KEY,"
+ " [Days Since Last Shipped] LONG DISCRETIZED(CLUSTERS) PREDICT, "
+ " [Store Id] LONG DISCRETE, "
+ " [Quantity] LONG DISCRETIZED(CLUSTERS) PREDICT_ONLY, "
+ " [Vendor Name] TEXT DISCRETE, "
+ " [Product Type] TEXT DISCRETE) "
+ "USING Microsoft_Decision_Trees";
try
{
cn.Open();
cmd.ExecuteNonQuery();
cn.Close();
}
catch(Exception e)
{
MessageBox.Show(e.Message);
}MSDMine was an implementation "detail" in SQL Server 2000 and it was never intended to connect directly to the MSDMIne provider. You can do all the same using MSOLAP. If you want to use local mining models, eliminate datasource, and set the connection string parameter Location to a file name.
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment