Unable to load parquet file from azure storage account

Blasko, Dan W 40 Reputation points
2025-01-21T13:07:44.36+00:00

I have created a credential and created a data source.

I have placed a csv and a parquet file on the azure DL G2 storage account.

I run this and it returns the first column of data as expected...........

SELECT id FROM OPENROWSET(

BULK 'calendar2.csv',

DATA_SOURCE = 'crm_ods_ds',

FORMAT = 'CSV',

firstrow = 2

) WITH (id varchar(18) 1

) AS DataFile;

I run either of these two and get file does not exist or access denied error message.

SELECT * FROM OPENROWSET(

BULK 'calendar.parquet',

DATA_SOURCE = 'crm_ods_ds',

FORMAT = 'PARQUET'

) AS DataFile;

SELECT * FROM OPENROWSET(

BULK 'calendar',

DATA_SOURCE = 'crm_ods_ds',

FORMAT = 'PARQUET'

) AS DataFile;

Msg 16535, Level 16, State 1, Line 69

Cannot bulk load. The file "https://ecrmdlstoragedev.blob.core.windows.net/crm-ods/calendar/calendar.parquet" does not exist or you don't have file access rights.

Since the csv file works, i do not see how it could be a permission issue since they are in the same folder.

Azure Storage Accounts
Azure Storage Accounts
Globally unique resources that provide access to data management services and serve as the parent namespace for the services.
3,347 questions
{count} votes

1 answer

Sort by: Most helpful
  1. Hari Babu Vattepally 1,635 Reputation points Microsoft Vendor
    2025-01-21T14:31:14.98+00:00

    Hi @Blasko, Dan W,

    Greetings! Welcome to Microsoft Q&A Forum, thanks for posting your query here.

    As per the provided error message, we see that you are encountering an issue loading a parquet file from Azure Storage using the OPENROWSET function. Since the CSV file loads successfully, the problem might be related to the specific configuration or permissions for the Parquet file.

    Please follow the below suggestions and give a try:

    1. Please ensure the file path and name are accurate, including case sensitivity. The error message suggests the file may not exist or there could be access rights issues. Make sure that the file calendar.parquet is actually located in the specified directory.
    2. Although the csv file works fine, but the parquet file might have different permissions. Make sure the credentials you are using have read access to the parquet file. Please check for the appropriate permissions for the storage account. Please make sure to check both at share-level and file-level permissions.
    3. Please ensure the appropriate Azure role is assigned for accessing the Parquet file. Suitable roles include Storage Blob Data Reader or Storage Blob Data Contributor.
    4. Please ensure that the database scoped credential you created is properly configured to access the storage account. If you are using a Shared Access Signature (SAS), verify that it has the necessary permissions and is not expired.
    5. Also, please make sure that you are specifying the correct format in your OPENROWSET function. The format should be set to 'PARQUET' as you have done but confirm that the file is indeed in the Parquet format.
    6. Please verify that the DATA_SOURCE you are referencing (crm_ods_ds) is properly configured to point to the Azure storage account and is using the correct credentials.

    After verifying all these aspects, if issues persist, please test with a different Parquet file to eliminate any file-specific problems. Also, please review the Azure storage logs for more detailed error messages that could offer further insights.

    Please refer the below links for additional information:

    I hope the above suggestions resolves issue. If the issue persists, please feel free to reach us for the further assistance. We will glad to assist you closely.

    Please do consider to “up-vote” wherever the information provided helps you, this can be beneficial to other community members.


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.