Using the Firestore Source Component

The Firestore Source Component is an SSIS data flow pipeline component that can be used to read/retrieve data from Firestore.

The component includes the following four pages to configure how you want to read data:

  • General
  • Document Designer
  • Columns
  • Advanced

General Page

The General page of the Firestore Source Component allows you to specify the general settings of the component.

Firestore Source General Page

Connection Manager

The Firestore Source Component requires a connection in order to connect to a Firestore instance. The Connection Manager drop-down will show a list of all Firestore connection managers that are available to your current SSIS package.

Database

This option lists all the available Databases in the Firestore instance. After selecting the Database you wish to read from, the Collection drop-down will be populated with the available Collections in the selected Database.

Note: you may select the refresh icon on the right to refresh the list of databases.

Collection

This option lists all the Containers available in the selected Database.

Note: you may select the refresh icon on the right to refresh the list of collections.

Output As Raw Text

The Output as Raw Text option specifies whether the output should be one single output column that contains the values in Raw Text format for each row returned by Firestore. The Document Designer Page is not available when this option is selected.

Advanced Settings

This option navigates to the Advanced Page of the Firestore Source Component.

Query

This textbox allows you to specify a query in order to retrieve and filter your data from Firestore.

Expression fx Icon

Click the blue fx icon to launch SSIS Expression Editor to enable dynamic updates of the property at run time.

Generate Documentation Icon

Click the Generate Documentation icon to generate a Word document that describes the component's metadata including relevant mapping, and so on.

Document Designer Page

The Document Designer page allows you to build the design of the document you are trying to read or import the design from an existing document. This page is only available for Document and Document Change Feeds Source Types.

Firestore Source Editor Document Designer

The Document Designer includes the following two tabs:

  • Details View
  • Additional Settings

In the Details View tab, the top part of the page is used to manually configure the nodes in the design:

  • Add Node: This button will add a new node to your Document design.
  • Remove Nodes: This button will remove a node from your Document design.
  • Direction buttons: These buttons can be used to rearrange the position of the nodes.
  • Rename Nodes: This option allows you to specify how the node name should be represented.
    • Use Qualified Names: When this option is selected, the output/column name will be set to the full qualified node name based on the node location in the document.
    • Use Short Names: When this option is selected, the output/column name will be set to the given Node Name directly.
  • Filter Columns: This option allows you to show or hide certain Columns in the grid.
    • Show Basic Columns: When this option is selected, only basic columns will be shown in the grid.
    • Show All Columns: When this option is selected, all available columns will be shown in the grid.
  • Filter Nodes: This option allows you to filter the list of nodes shown in the grid by typing a keyword in the textbox.

The Details View grid consists of:

  • Node Type: This option allows you to specify the type of the Node in your document design. There are four options available:
    • Array
    • Object
    • Value
    • Raw: This type can be used when trying to retrieve data under a node exactly as it is in the document.

  • Node Name: The Name of the Node in the document.
  • Output/Column Name: The name that will be set for the output or the column of a node.
  • Is Repeated: This option allows you to specify if a node is repeated within a document (Available when Show All Columns is selected).
  • Output type: The type of output for a node such as a Column or a Secondary Output depending on the Node Type.
  • Output Settings: This option allows you to specify the settings of each output such as the datatype of Value Node Types.

In the Additional Settings tab, you will find the following options:

Firestore Source - Document Designer - Additional Settings

  • Encoding:  You may select the encoding from the available dropdown list.
  • Null Mode: This option allows you to specify the handling of Null values.
  • 'Is Repeated' Text Qualifier: This option allows you to specify the Text Qualifier used in a document when the Is Repeated property is set to True for one or more nodes. There are four options available:
    • Double-quote(“)
    • Single-quote (‘)
    • Tick (`)
    • None
    • Node Names are Case Insensitive: When this option is enabled the node name's case sensitivity will be ignored.
  • 'Is Repeated' Text Delimiter: This option allows you to specify the Text Delimiter used in a document when the Is Repeated property is set to True for one or more nodes. There are seven options available:
    • Newline (\n)
    • Carriage Return (\r)
    • Semicolon (;)
    • Colon (:)
    • Comma (,)
    • Tab (\t)
    • Vertical Bar (|)
Import

This option allows you to import the design of your document from one of the following four sources:

  • Designer Settings: Import the design from an existing .designer.settings file.
  • Document (Firestore): Import the design based on the retrieved document from the connection manager.
  • JSON (Local File): Import the design based on a JSON file on your local file system.
  • JSON Schema (Local File): Import the design based on a JSON Schema file on your local file system.
Firestore Item Importer

When selecting the Item (Firestore) Import option, the Firestore Item Importer window will open which allows you to specify a query that will set the design of the Source Component based on the retrieved document.

Firestore - Document Importer

  • Database: This option allows you to select the database.
  • Collection: This option allows you to select the collection you would be importing.
  • Documents to scan: This option allows you to specify the maximum number of retrieved documents that will be used to set the design of the Source Component. Setting this option to 0 will read all the retrieved documents.

Columns Page

The Columns page of the Firestore Source Component shows you the available columns based on the settings on the Document Designer page.

Firestore Source - Columns Page

On the top left of the grid, you can see a checkbox, which can be used to toggle the selection of all available fields. This is a productive way to check or uncheck all available fields. The Columns Page grid consists of:

  • Include Field Checkbox: A checkbox that determines if the field will be available as an output column.
  • Column Name: Column that will be retrieved from the document.
  • Data Type: The data type of this field.
Hide Selected Fields

When the Hide Selected Fields checkbox is checked selected output columns will be hidden.

Hide Unselected Fields

When the Hide Unselected Fields checkbox is checked, unselected columns will be hidden.

Filter

The visible output columns can be filtered by entering text in the Filter text box.

Note: As a general best practice, you should only select the fields that are needed for the downstream pipeline components. Do this on the columns page using the checkboxes or on the General page by removing the column from the command entirely.

Advanced Page

The Advanced page of the Firestore Source Component shows you additional options when retrieving data from Firestore.

Firestore Source - Advanced Page

    Page Size

    This option can be used to set the maximum number of rows on a single page. You may leave this at 0 to send the entire request  without pagination.

    Max Document Count

    This option can be used to set the maximum number of documents returned. You may set this to 0 to return all documents.