--- title: "PredictNodeId (DMX) | Microsoft Docs" ms.date: 06/07/2018 ms.prod: sql ms.technology: analysis-services ms.custom: dmx ms.topic: conceptual ms.author: owend ms.reviewer: owend author: minewiskan --- # PredictNodeId (DMX) [!INCLUDE[ssas-appliesto-sqlas](../includes/ssas-appliesto-sqlas.md)] Returns the Node_ID of the node to which the case is classified. ## Syntax ``` PredictNodeId() ``` ## Applies To A scalar column. ## Return Type \ ## Examples The following example returns whether the specified individual is likely to buy a bicycle, and also returns the nodeID of the node that they are most likely to be part of. ``` SELECT [Bike Buyer], PredictNodeId([Bike Buyer]) From [TM Decision Tree] NATURAL PREDICTION JOIN (SELECT 28 AS [Age], '2-5 Miles' AS [Commute Distance], 'Graduate Degree' AS [Education], 0 AS [Number Cars Owned], 0 AS [Number Children At Home]) AS t ``` You could then use the following statement to determine what is contained within the node: ``` SELECT NODE_CAPTION FROM [TM Decision Tree].CONTENT WHERE NODE_UNIQUE_NAME= '00000000100' ``` ## See Also [Data Mining Extensions (DMX) Function Reference](../dmx/data-mining-extensions-dmx-function-reference.md) [Functions (DMX)](../dmx/functions-dmx.md) [General Prediction Functions (DMX)](../dmx/general-prediction-functions-dmx.md)