Skip to content

Upload Files to MS SQL ​

Overview ​

On the MS SQL DBMS managed services, access to local disks is not allowed.
Therefore, the only way to access files from the SQL Server is to place them on a remote share on a VM that is a member of the same resource domain as the SQL Server, granting the appropriate rights to the SQL service account.

The Upload Files action eliminates the need for creating shares on other VMs, enabling direct upload of certain file types to the SQL system.

File transfer is performed using an S3 bucket, analogous to the Import DB functionality.


Target Services ​

The feature is available for:

  • Managed MS SQL Server

These service types differ in permissions and resulting capabilities.

Service Actions by Type ​

Below you find the supported tasks per service type.
Each section lists what can be done via SSMS / SQL Agent Jobs and what’s exposed through the Portal.

Managed MS SQL Server ​

PortalSSMS / JobsAction
Not AvailableBulk InsertAvailable
AvailableLoad Assemblies / CertificatesN / A
Not AvailableExecute SQL ScriptsAvailable

Details:

  • Bulk Insert – used for large data imports into SQL tables.
  • Load Assemblies / Certificates – upload custom CLR assemblies or certificates through portal UI only.
  • Execute SQL Scripts – run T‑SQL from files or jobs.

Supported File Types ​

Each file type has a specific purpose in SQL Server workflows.
This section groups them logically for quick reference.

Bulk Insert Files ​

File TypeExtension
XML Data.xml
Format File.fmt
Text File.txt
CSV File.csv

Usage:
Used for structured or delimited data import into SQL tables using BULK INSERT or OPENROWSET.


Script and Library Files ​

File TypeExtension
SQL Script.sql
CLR Library.dll

Usage:

  • .sql – Execute schema changes, queries, or automation scripts.
  • .dll – Upload CLR assemblies for use within SQL Server.

Security and Key Files ​

Certificates use the .cer extension and are supported on all Managed SQL services. Key files use the .key extension and are supported only on SQL Always On deployments.

Usage:
Used for SQL Server certificate or key backups and restorations.

NOTE

For SQL certificates and key files, always append the appropriate suffix (.cer or .key) to identify file type correctly as there are no predefined file extensions.


Upload Repository ​

Uploaded files are placed in the following repository on the target system: D:\FileRepository

Key points:

  • The repository folder path cannot be changed.
  • The upload action includes an optional cleanup step:
    • When enabled, it deletes all existing files and folders in the repository.
    • When disabled, new files are added, but files with the same name will be overwritten.
  • The target folder structure will mirror the hierarchy defined in the S3 bucket.

NOTE

Use repository cleanup carefully — it removes existing files prior to new uploads.


Restriction Enforcement ​

  • Files not matching the listed types are automatically deleted, as are files without extensions.
  • Renaming files in the repository is not possible after upload.