Solved

How could the Key column be included in a DMX query?

Posted on 2013-01-01
2
399 Views
Last Modified: 2016-02-18
How could the Key column be included in a DMX query under the Mining Model Prediction tab?

The model used, say DT (for Decision Trees), can list every input and/or predict column except for the Key column.

Is there a way or work-around to include this Key column?
0
Comment
Question by:rodqxo
2 Comments
 
LVL 19

Accepted Solution

by:
Kash earned 500 total points
ID: 38736138
this example may point you to the right direction >> http://technet.microsoft.com/en-us/library/cc280466%28v=sql.100%29.aspx
0
 

Author Comment

by:rodqxo
ID: 38749411
On BIDS/VS2008, I tried StructureColumn(‘KeyColumnName') but I get this error:
"The STRUCTURECOLUMN function cannot be used in the context ..."

Here's the DMX query I used:
SELECT StructureColumn('KeyColumn') From [AR]; where [AR] is an Association model.

I defined KeyColumn as a Key; as opposed to Input, Input+Predict, Predict only.

The [AR] model seems to be only aware of the Input and Predict columns. It is blind to the Key type column, i.e., KeyColumn.

Later on ...

Ok, got it. I should use it this way:
SELECT StructureColumn('KeyColumn') From [AR].CASES

But for now it does not work with a PREDICTION JOIN statement.

Thanks.
0

Featured Post

Maximize Your Threat Intelligence Reporting

Reporting is one of the most important and least talked about aspects of a world-class threat intelligence program. Here’s how to do it right.

Join & Write a Comment

Suggested Solutions

Title # Comments Views Activity
Write a function 5 25
Record extraction 3 14
Help with SQL Query 23 39
sqlseverexpress 2008 agent xps question 1 11
In this article I will describe the Detach & Attach method as one possible migration process and I will add the extra tasks needed for an upgrade when and where is applied so it will cover all.
Use this article to create a batch file to backup a Microsoft SQL Server database to a Windows folder.  The folder can be on the local hard drive or on a network share.  This batch file will query the SQL server to get the current date & time and wi…
Here's a very brief overview of the methods PRTG Network Monitor (https://www.paessler.com/prtg) offers for monitoring bandwidth, to help you decide which methods you´d like to investigate in more detail.  The methods are covered in more detail in o…
This video shows how to remove a single email address from the Outlook 2010 Auto Suggestion memory. NOTE: For Outlook 2016 and 2013 perform the exact same steps. Open a new email: Click the New email button in Outlook. Start typing the address: …

758 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

18 Experts available now in Live!

Get 1:1 Help Now