Forum Discussion

DiKi-I's avatar
DiKi-I
Post Partisan
1 year ago
Solved

Generate data script for warehouse

  I have to migrate the data from fabric warehouse to another fabric warehouse in different tenant. How I can easily migrate the data?   I don't see the script generate option after connecting t...
  • v-karpurapud's avatar
    1 year ago

    Hi DiKi-I 

    Welcome to the Microsoft Fabric Community Forum.
     

    Microsoft Fabric does not natively support direct cross-tenant data migration for warehouses. Additionally, it does not support traditional SQL Server Management Studio (SSMS) script generation features like “Generate Scripts” or “Tasks- Export Data,” as Fabric warehouses are not full SQL Server instances and lack full SQL Server Management Objects (SMO) compatibility. Since you are migrating data across tenants, cross-tenant queries or direct data transfer via T-SQL or Linked Servers is not possible.
     

    To perform the migration, export the data from the source Fabric Warehouse using supported methods such as Fabric Pipelines, Azure Data Factory, or Notebooks, and write the data into an intermediate storage location like Azure Blob Storage or OneLake in a portable format such as CSV or Parquet. Ensure that a service principal is configured in the source tenant to enable secure access to the storage location. Once the data is exported, transfer it to the target tenant using tools like AzCopy or Azure Storage Explorer.

     

    If needed, configure secure cross-tenant access using Azure B2B collaboration or Shared Access Signature (SAS) tokens. In the destination tenant, configure a service principal with appropriate permissions, and then use T-SQL commands like COPY INTO, or Fabric Pipelines or Notebooks, to load the data into the target Fabric Warehouse. This method ensures secure, scalable, and Microsoft-supported migration across tenants.

    Thank you for being part of Fabric Community Forum.

    Regards,
    Karpurapu D,
    Microsoft Fabric Community Support Team.