Bagikan melalui


Data Mining Query Task

The Data Mining Query task runs prediction queries based on data mining models built in Analysis Services. The prediction query creates a prediction for new data by using mining models. For example, a prediction query can predict how many sailboats are likely to sell during the summer months or generate a list of prospective customers who are likely to buy a sailboat.

The query is a Data Mining Extensions (DMX) statement. The DMX language is an extension of the SQL language that provides support for working with mining models. For more information about how to use the DMX language, see Data Mining Extensions (DMX) Reference.

The task can query multiple mining models that are built on the same mining structure. A mining model is built using one of the data mining algorithms that Analysis Services provides. The mining structure that the Data Mining Query task references can include multiple mining models, built using different algorithms. For more information, see Mining Structures (Analysis Services - Data Mining) and Data Mining Algorithms (Analysis Services - Data Mining).

The prediction query that the Data Mining Query task runs returns a result that is a single row or a data set. A query that returns a single row is called a singleton query: for example, the query that predicts how many sailboats will be sold during the summer months returns a number. For more information about prediction queries that return a single row, see Creating DMX Prediction Queries.

The query results are saved to tables. If a table with the name that the Data Mining Query task specifies already exists, the task can create a new table, using the same name with a number appended, or it can overwrite the table content.

If the results include nesting, the result is flattened before it is saved. Flattening a result changes a nested result set to a table. For example, flattening a nested result with a Customer column and a nested Product column adds rows to the Customer column to make a table that includes product data for each customer. For example, a customer with three different products becomes a table with three rows, repeating the customer in each row and including a different product in each row. If the FLATTENED keyword is omitted, the table contains only the Customer column and only one row per customer. For more information, see SELECT (DMX).

The Data Mining Query task requires two connections. The first connection is an Analysis Services connection manager that connects either to an instance of Microsoft SQL Server Analysis Services or to an Analysis Services project that contains the mining structure and the mining model. The second connection is an OLE DB connection manager that connects to the SQL Server database that contains the table to which the task writes. For more information, see Analysis Services Connection Manager and OLE DB Connection Manager.

Configuring the Data Mining Query Task

You can set properties through SSIS Designer or programmatically.

For more information about the properties that you can set in SSIS Designer, click one of the following topics:

Note

The Data Mining Query Editor has no Expressions page. Instead, use the Properties window to access the tools for creating and managing property expressions for properties of the Data Mining Query task.

For more information about how to set these properties in SSIS Designer, click the following topic:

Configuring the Data Mining Query Task Programmatically

For more information about programmatically setting these properties, click one of the following topics:

Integration Services provides tasks that perform other business intelligence operations, such as running Data Definition Language (DDL) statements and processing analytic objects.

For more information about other business intelligence tasks, click one of the following topics:

External Resources

Integration Services icon (small) Stay Up to Date with Integration Services

For the latest downloads, articles, samples, and videos from Microsoft, as well as selected solutions from the community, visit the Integration Services page on MSDN or TechNet:

For automatic notification of these updates, subscribe to the RSS feeds available on the page.