Events
Mar 31, 11 PM - Apr 2, 11 PM
The biggest SQL, Fabric and Power BI learning event. March 31 – April 2. Use code FABINSIDER to save $400.
Register todayThis browser is no longer supported.
Upgrade to Microsoft Edge to take advantage of the latest features, security updates, and technical support.
Caution
This function is in the process of being removed due to internal inconsistencies.
Review the example section for a workaround using a DMX expression.
Returns a value of a numeric expression evaluated over a data mining model.
Predict(Mining_Model_Name,String_Expression)
Mining_Model_Name
A valid string expression that represents the name of a mining model.
String_Expression
A valid string expression that evaluates to a valid DMX expression for the specified mining model.
The Predict function evaluates the specified string expression within the context of the specified mining model.
Data mining syntax and functions are documented in Data Mining Expressions (DMX) reference.
The following example predicts name of the cluster and the distance from it of a particular customer using the Customer Clusters mining model:
WITH MEMBER MEASURES.CLNAME AS
PREDICT("Customer Clusters", "Cluster()")
MEMBER MEASURES.CLDISTANCE AS
PREDICT("Customer Clusters", "ClusterDistance(Cluster())")
SELECT {MEASURES.CLNAME, MEASURES.CLDISTANCE} ON 0
FROM [Adventure Works]
WHERE([Customer].[Customer Geography].[Customer].&[12012])
Events
Mar 31, 11 PM - Apr 2, 11 PM
The biggest SQL, Fabric and Power BI learning event. March 31 – April 2. Use code FABINSIDER to save $400.
Register today