Location provided by DATA_SOURCE 'sales_data' cannot contain any wildcards.

siddharth ranjan 0 Reputation points
2024-09-02T11:08:28.6633333+00:00

Getting this error while following instructions in https://microsoftlearning.github.io/dp-203-azure-data-engineer/Instructions/Labs/03-Transform-data-with-sql.html

while running following code:
USE Sales;

GO;

SELECT Item AS Product, SUM(Quantity) AS ItemsSold, ROUND(SUM(UnitPrice) - SUM(TaxAmount), 2) AS NetRevenue

FROM OPENROWSET( BULK 'sales/csv/*.csv',

DATA_SOURCE = 'sales_data', FORMAT = 'CSV', PARSER_VERSION = '2.0', HEADER_ROW = TRUE ) AS orders GROUP BY Item;

Usage of filepath function with DATA_SOURCE 'sales_data' might result in unexpected results if number of wildcards in data source LOCATION changes. Location provided by DATA_SOURCE 'sales_data' cannot contain any wildcards.

This question is related to the following Learning Module

Azure Training
Azure Training
Azure: A cloud computing platform and infrastructure for building, deploying and managing applications and services through a worldwide network of Microsoft-managed datacenters.Training: Instruction to develop new skills.
1,527 questions
{count} votes

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.