Store query history in a cloud service

This topic provides a step-by-step procedure explaining how to store a query history file in a cloud service like OneDrive, allowing access from different locations, for example, home and work environments.

Prerequisites

  • Download and install OneDrive on your machine.

Note

OneDrive is preinstalled on Windows 10 and Windows 11.

  • Set up OneDrive on Windows:
    • If no accounts are signed in to OneDrive, see this OneDrive documentation.
    • If an account is already signed in to OneDrive, see this OneDrive documentation.

Workflow

1. Create a folder on OneDrive.

2. Export query history as a .csv file to the OneDrive folder.

3. Share the OneDrive folder or file with other users.

Create a folder on OneDrive

1. Open File Explorer on your machine.

2. Right-click the OneDrive folder and select New > Folder.

3. Specify the folder name, then press Enter.

Export query history as a .csv file to the OneDrive folder

1. Open dbForge Studio for SQL Server.

2. Open the Query History document in one of these ways:

  • In the top menu, select View > Other Windows > Query History.
  • Press Ctrl+Alt+H.

3. Optional: Click Period to view queries for a predefined time range or to define a custom time range for queries executed on this instance on your machine.

Specify a time period for queries

4. Click Export to CSV to export data to a .csv file.

5. Specify the file location, then click Save.

The file appears in the specified OneDrive folder.

Displaying file in the specified OneDrive folder

Share the OneDrive folder or file with other users

1. Right-click the folder or file you want to share and select OneDrive > Share.

2. Enter the email addresses of the users you want to share the folder with.

3. Select the access permission:

  • Can edit – Allows the specified users to make any changes.
  • Can view – Provides read-only access to users.
  • Can’t download – Allows the specified users to view the folder without downloading it.

Warning

The Can edit access permission allows the specified users to add the shared folder to their own OneDrive and view all its contents. If you want to share only a specific file, add it to a separate folder and share that folder instead.

4. Optional: Add a message.

5. Choose one of the ways to share the folder:

  • Click Send to share the folder with the specified users.
  • Click Copy link to copy the link to the clipboard. Anyone with the link will have the specified access permissions.

Tip

To change the link permissions, click Link settings next to Copy link, select the shared options, and click Apply.

Change the link permissions in OneDrive