I spent the last days programming a managed datamining plugin-algorithmn for SSAS 2005 and have troubles with the Prediction-Method.
Die Prediction-Methode of the "Shell-Algorithm" leads to an error-message on execution of the prediction-query (Internal Error: Unexprected Error ... dmxpredict.cpp Row 205 ...).
Can anyone provide me with a very simple implementation of this Method which just says that for every output-attribute the first (discrete) state should be predicted with a probability of, let's say, 90 % ?
After I've written my first Plugin-Algorithmn, I have some general questions about the Managed Plugin-Algorithmn wrapper.
What does the Property "support" express in view of predictions? Is it the overall number of cases the found rule works for?
What's the difference between AdjustedProbability and Probability ?
There is a probability for a specific StateStatistic and one for the whole AttributeStatistic. What does the latter one express? Perhaps the overall probability that the discovered rules will lead to correct results for this attribute ? Let's say I have two rules for an attribute. Rule A has a probability of 0.5 and Rule B has a probability of 0.66. What would be AdjustedProbability.Probability in the case? The mean of 0.5 and 0.66 ?
I'm here once again asking for help. Here's my problem:
I have a table that I use in my text mining clustering third-party algorithm. The table is as follows:
ID: primary key (int)
ID_DOC: an ID I use to know from what document a term came from (int)
ID_TERMO: the term ID (int)
TERMO: the term itself (varchar(max))
FREQ: the term frequency, usually TFxIDF (real)
Alright... I need the term itself to do some visualization. What I want to do is to get each case's term and store'em on a vector<char*>. So I did some changes on the ProcessCase method. In this method the data (each variable of the case) can be accessed rolling over the case using a DM_STATE_VALUE* as follows:
DM_STATE_VALUE* xpto = (DM_STATE_VALUE*) rgValue;
for(unsigned int i=0;i<_cAttribute;i++) { // _cAttribute is the number of variables
double aux = xpto.r8;
//Do some calculation using aux
}
Alright... It works quite well when I only have real and int data types on the database. But how the get the term collumn (varchar(max)) ?
How to modify the DM_STATE_VALUE union to accept strings as well ?
I want to create a Data Mining Plugin-Algorithmn that uses existing mining models in the current DB. Is there a way to get a AdomdConnection from within an (Managed) Plugin-Algorithmn? This Connection should point to the current SSAS-Database.
I have a code for Nearest neighbour algorithm, I want to build a datamining algorithm using that code..
I have the following link that includes the source code for a sample plug-in algorithm written in C#.
(managed plug-in framework that's available for download here: )http://www.microsoft.com/downloads/details.aspx?familyid=DF0BA5AA-B4BD-4705-AA0A-B477BA72A9CB&displaylang=en#DMAPI.
But i am confused on where to insert my algorithm logic?
as we know we get clustering algorithm with managed plugin algorithm API
does anyone have developed any other plugin algorithm as i want to check what are the things that needs to be modified. i am not data mining algorithm developer but i just want to check where we have to make changes. i would be better if i get source code for algorithm other than clustering
I'm following the steps of the tutorial on how to construct a managed data mining plugin in C#.
Once created the Metadata, Algorithm and Navigator classes I tried to register it on Analisys Service by running the XMLA template written on the tutorial but I got the following error:
Unable to retrieve a list of supported data mining algorithms. Make sure you are connected to the correct Analysis Services server instance and the Analysis Services server named localhost is running and configured properly. You can continue with a default list of data mining algorithms
The GUID in the XMLA is correct as so the service name. The SQL Server engine runs fine.
I noticed that when I run this XMLA, the file msmdsrv.ini is modified, so in DataMining/Algorithms session a new entry is correctly created, enabled and the GUID is also set correct.
I also tried to ignore the XMLA setting up msmdsrv.ini manually but it also didn't work.
The build process is fine, both DMPluginWrapper and the Shell are registered by gacutil and I restarted (also try to stop and start) the server.
I've developed a clustering plugin for SQL Server 2005 but now I want to port the .dll so my algorithm can run on another machine. Both machines have SQL Server 2005 installed, but different versions of Windows.
What are the steps I need to follow to port the plugin ?
I am working on an AS Algorithm Plugin . I want to debug it in the AS Server, but I cant figure out how it works. Now I every time install and deploy the plugin, but if I catch an exception, it just shows me the message, not the stack trace. Anyone, something friendlier method?
hello,everyone,I also met a problem. I stoped the SQL Server Analysis Services first, and registered the GAC successfully, then modified the msmdsrv.ini manually.In fact,I found the format of my msmdsrv.ini is diffirent from the one mentioned in the tutorial,it just like below:
when i restarted the the AS, some error information displayed in event viewer, " can't load MyCompany_Mamaged_Plugin_Algorithm data mining Algorithm provider(ProgID, can't create Algorithm Provider program for MyCompany_Managed_Plugin_Algorithm, ProgID does not exist in the server configuration file"
I am confused by it and have not any idea to solve it. some one can give tips? thanks.
We have a large number of SPs in our databases and decided it was time to get some source control. I have VSTS team explorer installed and working in visual studio, but I cannot get the plugin for SSMS to work - it just says none in the current source control plug-in dialogue box - nothing when I drop it down either.
I'm doing a custom clustering plugin for text to pre-process ("clean" the texts), calculate weights, estimate the number of clusters (using the PBM index) and finally, do the actual clustering.
So... I've made each of these modules on C++ and I'm putting them all togheter on the plugin.
My database (MDB file) has only one table, with only two fields within: a key (auto-incremental) and a small text. What I intend to do is to get the text in each test case, store them togheter somewhere and call my classes to cluster these texts.
I'm trying to log the texts in a file (just a test) on the ProcessCase method, in the CaseProcessor class. I've did it with no problems with numerical data.
But when I load the MDB file on the Mining Structures Wizard, it says the content type of the field holding the texts is "Continous" and the data type is "Text". Actually, when I saw it I didn't really mind.
But when I run the mining model it gives me the following error: "Error 1 Error (Data mining): The data type of the Table1.Texto mining structure column must be numeric since it has a continuous content type (Content is set to Continuous or Key Time or Key Sequence). 0 0 "
So... How do I change this content type ? (the content type combobox on the Mining Structures Wizard couldn't the changed)
Well... As I said in other topics, I'm doing a clustering plugin for text mining. I'm facing many problems and, with your help, solving them one by one.
First of all, thanks a lot again.
Well... I've made a clustering function that is actually working very well. But I'm exporting its results to a log file I use as an algorithm trace for debugging.
My clustering method returns a vector containing information of what cluster each register belongs. For instance:
vector[0] = 1 -> The register of index 0 belongs to cluster 1.
vector[1] = 9 -> The register of index 1 belongs to cluster 9.
vector[2] = 2 -> The register of index 2 belongs to cluster 2.
...
And so on.
But... I know that none of the Navigation methods receives a structure like this one discribed above. I only use it to log the results to debug the algorithm.
But how to pass this information (what register (or test case) belongs to what cluster) to the Navigation ?
Thanks a lot again, and any help will be very appreciated.
Hello people :-)I'm doing some development work with Visual Studio 2005 and SQLServer 2000. My SQL DB is running on a Windows 2000 Server box in the office, and I'm doing the development on my XPPro workstation. Now I've been trying to connect to the Win2000 box though VS and although I can see the server and the DB when I hit ok I get this error"The SQL server specified by these connection propertise does not support managed objects"What the heck does that mean?any help would be great :-)
I have a SQL Server project in Visual Studio 2005 which deploys an assembly to SQL Server 2005 containing various stored procedures user defined functions. Is there any way to tell Visual Studio to drop/create the stored procedures in a schema other than dbo?
ie: User.ChangePassword instead of dbo.ChangePassword.
In VS 2003 I used SQLDMO (Com Object) to list all available SQL Servers. Is in SQL Server 2005 a managed .net Component that can do that task?Thanks,Rainer.
Can anyone explain why when I look at table using enterprise manager, highlight a table, all tasks, maanage indexes why only 1 index appears and when I look at the same table in sysindexes is says that there are 8 indexes. This is the sql code I executed: select object_name(id), indid from sysindexes where object_name(id) = 'tbh_matter_summ'
Is it possible that there is a problem with the database?
I have an MDS entity which will be managed in excel. I do not want the user to enter the Code and Name so I have configured code to auto generate and name to default to another attribute value. I have then hidden code and name in excel.
When I use excel and enter the attribute and publish, the name column is blank in the MDS table.Am I missing something here with the defaulting?The Action is defined as 'Name Defaults to Country'. Where Country is the attribute I am populating.
SQL Server 2005 gives you a possibility to create managed triggers. In a managed trigger I can create a new thread and process trigger event in various ways. My question is that are there any reasons why I should NOT start new threads in database triggers? The following code shows how I could create new threads. Do you see that this could cause any errors or problems in SQL Server functionality? My goal is to minimize the trigger effects in a database overall performance.
'This handles database updates of AdventureWorks Person.Contact table. <Microsoft.SqlServer.Server.SqlTrigger(Name:="UpdateContact_Trigger", Target:="Person.Contact", Event:="FOR UPDATE")> _ Public Shared Sub UpdateContact_Trigger() 'Notify: SqlContext.Pipe.Send("Trigger FIRED")
Dim triggContext As SqlTriggerContext = SqlContext.TriggerContext() 'Ensure that it was update: If triggContext.TriggerAction = TriggerAction.Update Then
'Open a connection: Using conn As New SqlConnection("context connection=true") conn.Open() 'Fetch some information about the update: Using sqlComm As New SqlCommand sqlComm.Connection = conn sqlComm.CommandText = "SELECT ContactID, FirstName, LastName from INSERTED" Using rdr As SqlDataReader = sqlComm.ExecuteReader If rdr.Read Then 'Process the data in a separate thread. The thread could send a message to MSMQ about the change 'or process if differently. The purpose of using separate thread is avoid performance hit 'in the application / database operation. Dim oData As New TriggerData("update", rdr.GetInt32(0).ToString, "contact") Dim trd As New Threading.Thread(New Threading.ThreadStart(AddressOf oData.ProcessEvent)) trd.IsBackground = True trd.Start() End If End Using End Using End Using End If End Sub
Hi there, Values in my database need to updated periodically. The code, upon starting the application, queries the database and stores the values in the Application collection. This is to avoid making a database call everytime the values are needed (increases performance). The drawback is that changes to the database values are not updated in the code. How can I create a database trigger that will update the C# Application colllection whenever a table value is updated?
I have created a managed stored procdure in a sql server project in VS. I have put in the corect server name password and login fro the connection to the database. When I deploy however it doesn't deploy the stored proccdure to the database even though it says it has successfully deployed the stored procedure. Has anyone had this problem and how can you make sure it is deploying to the correct database.
Are there any additional documents or utilities that people would suggest for monitoring and managing CLR impact on SQL server resources and performance?
This seems like a simple question but I still haven't been able to get an answer from Microsoft Canada. We're looking at buying 75 device cals to connect to a single instance of SQL Server Standard Edition. Our question is on how those licenses are assigned and/or activated.
Do we need to manually do something for each station or is it an automated process done the first time a station connects to the server? We also wat to understand what happens when a workstation dies and is replaced by another one. Do you have to do something on the server to transfer the license to the new station ?
In other words, when using device cals (and/or user cals), do you have to do any type of license management or is it all transparent ?
I am stepping into the world of developing SSIS packages as part of a project I am working on, and I am kicking the tires at the moment, and I am having a couple of problems.
First, is there a really good source of 'how-to's in terms of developing against SSIS. There is plenty of documentation on MSDN/Technet, but there are NO books which cover managed DTS in ANY kind of depth.
Secondly, I am looking at bringing in an XML file programatcially, and linking in the columns I need. Works fine using the BI tools, but I get an error when I do it from visual studio.
The following code :
Code Block IDTSComponentMetaData90 xmlinputfile; Package package = CreatePackage("SSISPackage", "Test Package"); MainPipe pipe = AddDataFlowTask(package); pipelineEvents = new ComponentEvents(); xmlinputfile = pipe.ComponentMetaDataCollection.New(); // configure it up... xmlinputfile.ComponentClassID = "Microsoft.SqlServer.Dts.Pipeline.XmlSourceAdapter, Microsoft.SqlServer.XmlSrc, Version=9.0.242.0, Culture=neutral, PublicKeyToken=89845dcd8080cc91"; xmlinputfile.Name = "XML Source"; xmlinputfile.Description = "Source data in the data flow..."; CManagedComponentWrapper instance = xmlinputfile.Instantiate(); instance.ProvideComponentProperties(); // At this point you would normally associate with the runtime connection manager, // but as it is an xml file, we do not need to do that // We need to set the appropriate properties to look at our xml file... instance.SetComponentProperty("XMLData", @"C:filechangedtoprotecttheinnocent.xml"); instance.SetComponentProperty("XMLSchemaDefinition", @"C:filechangedtoprotecttheinnocent.xsd"); instance.SetComponentProperty("AccessMode", 0); instance.SetComponentProperty("UseInlineSchema", false); // We need to set output connections.... instance.AcquireConnections(null); instance.ReinitializeMetaData(); instance.ReleaseConnections();
IDTSVirtualInput90 vInput = xmlinputfile.InputCollection[0].GetVirtualInput(); // Iterate through the virtual input column collection. foreach (IDTSVirtualInputColumn90 vColumn in vInput.VirtualInputColumnCollection) {
}
When I go anywhere near the InputCollection[0], watch throws an exception, and the call to GetVirutalInput() throws the same exception which is :
System.Runtime.InteropServices.COMException was unhandled by user code Message="Exception from HRESULT: 0xC0048004" Source="Microsoft.SqlServer.DTSPipelineWrap" ErrorCode=-1073446908 StackTrace: at Microsoft.SqlServer.Dts.Pipeline.Wrapper.IDTSInputCollection90.get_Item(Object Index) at IntegrationServicesScratchPad._Default.btnExecute_Click(Object sender, EventArgs e) in C:Documents and SettingsjMy DocumentsVisual Studio 2005ProjectsIntegrationServicesScratchPadIntegrationServicesScratchPadDefault.aspx.cs:line 75 at System.Web.UI.WebControls.Button.OnClick(EventArgs e) at System.Web.UI.WebControls.Button.RaisePostBackEvent(String eventArgument) at System.Web.UI.WebControls.Button.System.Web.UI.IPostBackEventHandler.RaisePostBackEvent(String eventArgument) at System.Web.UI.Page.RaisePostBackEvent(IPostBackEventHandler sourceControl, String eventArgument) at System.Web.UI.Page.RaisePostBackEvent(NameValueCollection postData) at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)
Does anyone have any kind of clue as to what is going on. I have seen comments on here from other people in regards to errors with input columns?? The XML files work fine in the editor as I said, and the XSD was generated by the editor using the Generate XSD option.
When I try to deploy this managed stored proc assembly on SQL Server 2005 I get this error: Failed to initialize the Common Language Runtime (CLR) v2.0.50727 with HRESULT 0x8007000e. You may fix the problem and try again later I looked on the net but found no documentation about it. I know the CLR v2.0 is working as I have some ASP.NET apps running from this server that use it. Any ideas?
In a previous post in Installation and Setup I was having problems just getting an ASP.NET 2.0 app to run on my web server. Now I'm having some different weird security issues. I'm getting this message when just trying to open a database and put its contents into a gridview. Access to the ADO.net Managed Provider 'SqlClientFactory' was denied in the data source with ID 'sqlEmployees' because of security settings. I think this may have to do with our web server and our SQL server being separate machines. That always gives us issues. But I have impersonation=true in my web.config along with windows authentication and I have SQL Server configured with Windows and SQL authentication so things should be right, I'm thinking. Any ideas??
I am developing a managed stored procedure in VS.NET 2005 and I am trying to add a reference to an user developed assembly (not a system one) but adding a reference to it is not possible as it doesnt let me import assemblies but rather reference the few limited ones in a list. Why is this??
I have written a stored procedure using C#.NET. I deployed it to SQL Server, and everything works fine.
However, an Third-Party app needs to see what parameters it can use for this SP by executing sp_sproc_columns <SP name>
sp_sproc_columns
Seems to work on normal SP's written in T-SQL, but not on Managed SP's. On my SP, sp_sproc_columns does not seem to work. It does not return the parameters. On normal SP's, it does.