Using the Google Drive Destination Component

The Google Drive Destination component is an SSIS data flow pipeline component that can be used to write data to Google Drive. There are three pages of configuration:

  • General
  • Columns
  • Error Handling

The General page is used to specify general settings for the Google Drive Destination Component. The Columns page allows you to map the columns from upstream components to Google Drive fields in the destination object. The Error Handling page allows you to specify how errors should be handled when they occur.

General

The General page allows you to specify general settings for the component.

Google Drive Destination - General


Connection Manager

The Google Drive Destination Component requires a connection. The Connection Manager drop-down will show a list of connection managers that are available within the package.

Destination Object

The drop-down displays a list of objects including:

  • Folder
  • File
Action

The Action specifies how you want to write to Google Drive specified in the selected Connection Manager. There are 5 Actions:

  • Create: Creates new record(s)
  • Update: Updates a file's metadata and/or content
  • Delete: Deletes record(s)
  • Copy: Copies a source object to a destination object
  • Empty Trash: Permanently deletes all of the user's trashed files
Upload Type

The drop-down displays a list of objects including:

  • Simple: Use this upload type to quickly transfer a small media file (5 MB or less)
  • Multipart: Use this upload type to quickly transfer a small file (5 MB or less) and metadata that describes the file, in a single request.
  • Resumable: Use this upload type for large files (greater than 5 MB) in a resumable fashion
Duplicate Mode

The Duplicate Mode   specifies how to handle rows that try to either Copy to/Upload an item that already exists. There are 3 Modes:

  • Fail: Throws error if item exists. This can still be handled via the Error Handling
  • Auto Increment: Increments the number at the end of the item name. If one does not exists one is added. It continues to increment the number until no item with that name exists.
  • Overwrite: Replaces the existing item with the item being uploaded/moved to that location.
Refresh Component Button

Clicking the Refresh Component button causes the component to retrieve the latest metadata and update each attribute to its most recent metadata.

Map Unmapped Fields Button

By clicking this button, the component will try to map any unmapped Box attributes by matching their names with the input columns from upstream components. This is useful when your source component has recently added more columns, in which case you can use this button to automatically establish the association between input columns and unmapped destination attributes.

Clear All Mappings Button

By clicking this button, the component will reset all your mappings in the destination component.

Expression fx Button

Clicking the fx button to launch SSIS Expression Editor to enable dynamic update of the property at run time.

Generate Documentation Button

Clicking the Generate Documentation button to generate a Word document which describes the component's metadata including relevant mapping, and so on.

Columns

The Columns page of the Google Drive Destination Component allows you to map the columns from upstream components to the Google Drive destination fields.

In the Columns page, you would see a grid that contains four columns as shown below.

Google Drive Destination - Columns

  • Input Column: You can select an input column from an upstream component for the corresponding Google Drive field.
  • Destination Field: The Google Drive field that you are writing data.
  • Data Type: This column indicates the type of value for the current field.
  • Unmap: This column can be used to unmap the field from the upstream input column, or otherwise it can be used to map the field to an upstream input column by matching its name if the field is not currently mapped.

Error Handling

The Error Handling page allows you to specify how errors should be handled when they happen.

Google Drive Destination - Error Handling

There are three options available.

  1. Fail on error
  2. Redirect rows to error output
  3. Ignore error

When the Redirect rows to error output option is selected, rows that failed to write to Google Drive will be redirected to the 'Error Output' output of the Destination Component. As indicated in the screenshot below, the blue output connection represent rows that were successfully written, and the red 'Error Output' connection represents rows that were erroneous. The 'ErrorMessage' output column found in the 'Error Output' may contain the error message that was reported by the server or the component itself.


Enable Columns for Default Output

NewlyCreatedRecordId: Enable this option to get the Id value for the newly created record in the default output.

Google Drive Destination - Redirected outputs

Note: Use extra caution when selecting Ignore error option, since the component will remain silent for any errors that have occurred.