Power BI Refresh Error:
003139
What does this error mean?
The storage integration linked to an external stage cannot be found. This typically happens when a storage integration is dropped and recreated using CREATE OR REPLACE STORAGE INTEGRATION — Snowflake stores the association by internal ID, not by name, so the stage loses its link.
Common causes
- 1A storage integration was recreated using CREATE OR REPLACE STORAGE INTEGRATION, changing its internal ID
- 2The storage integration was explicitly dropped without updating the stages that reference it
- 3Terraform or IaC tooling replaced the storage integration resource, generating a new internal ID
- 4The storage integration was renamed — Snowflake stages reference by ID, not by name
- 5Cross-account or cross-region migration where the integration was recreated
How to fix it
- 1Re-link the stage to the (new) storage integration: ALTER STAGE <stage_name> SET STORAGE_INTEGRATION = <integration_name>.
- 2After recreating a storage integration, always update all stages that referenced the old one.
- 3Verify the fix: SHOW STAGES and check the storage_integration column.
- 4If using Terraform, add a lifecycle dependency so stages are updated after the integration is replaced.
- 5List affected stages: SELECT * FROM INFORMATION_SCHEMA.STAGES WHERE STORAGE_INTEGRATION IS NOT NULL.
Frequently asked questions
Official documentation: https://docs.snowflake.com/en/user-guide/data-load-bulk-ts