SSIS を使ってAzure Data Lake Storage データをSQL Server にインポート

SSIS components for ADLS を使用して簡単にSQL Server へAzure Data Lake Storage をバックアップします。

古川えりか
コンテンツスペシャリスト

最終更新日:2011-07-10
azuredatalake ロゴ

CData

ssis ロゴ画像
SSIS ロゴ

こんにちは!ドライバー周りのヘルプドキュメントを担当している古川です。

SQL Server に基幹業務データのバックアップを保管しておくことは、ビジネス上のセーフティネットとなります。また、ユーザーはSQL Server のバックアップデータからレポーティングや分析を簡単に行うことができます。

ここでは、SQL サーバー SSIS ワークフロー内でCData SSIS Tasks for ADLS を使用して、Azure Data Lake Storage データをMicrosoft SQL Server データベースに転送する方法を説明します。

Components の追加

開始するには、新しいAzure Data Lake Storage ソースとSQL Server ADO.NET 転送先を新しいデータフロータスクに追加します。

The Data Flow task used in this example.(Salesforce is shown.)

新しいコネクションマネジャーを作成

以下のステップに従って、接続マネジャーでAzure Data Lake Storage 接続プロパティを保存します。

  1. Connection Manager ウィンドウで、右クリックで[New Connection] を選択します。Add SSIS Connection Manager ダイアログが表示されます。
  2. [Connection Manager type]メニューでADLS を選択します。CData Azure Data Lake Storage Connection Manager が表示されます。
  3. 接続プロパティを構成します。

    Authenticating to a Gen 1 DataLakeStore Account

    Gen 1 uses OAuth 2.0 in Azure AD for authentication.

    For this, an Active Directory web application is required. You can create one as follows:

    1. Sign in to your Azure Account through the .
    2. Select "Azure Active Directory".
    3. Select "App registrations".
    4. Select "New application registration".
    5. Provide a name and URL for the application. Select Web app for the type of application you want to create.
    6. Select "Required permissions" and change the required permissions for this app. At a minimum, "Azure Data Lake" and "Windows Azure Service Management API" are required.
    7. Select "Key" and generate a new key. Add a description, a duration, and take note of the generated key. You won't be able to see it again.

    To authenticate against a Gen 1 DataLakeStore account, the following properties are required:

    • Schema: Set this to ADLSGen1.
    • Account: Set this to the name of the account.
    • OAuthClientId: Set this to the application Id of the app you created.
    • OAuthClientSecret: Set this to the key generated for the app you created.
    • TenantId: Set this to the tenant Id. See the property for more information on how to acquire this.
    • Directory: Set this to the path which will be used to store the replicated file. If not specified, the root directory will be used.

    Authenticating to a Gen 2 DataLakeStore Account

    To authenticate against a Gen 2 DataLakeStore account, the following properties are required:

    • Schema: Set this to ADLSGen2.
    • Account: Set this to the name of the account.
    • FileSystem: Set this to the file system which will be used for this account.
    • AccessKey: Set this to the access key which will be used to authenticate the calls to the API. See the property for more information on how to acquire this.
    • Directory: Set this to the path which will be used to store the replicated file. If not specified, the root directory will be used.

Azure Data Lake Storage Source の構成

以下のステップに従って、Azure Data Lake Storage の抽出に使用するクエリを指定します。

  1. Azure Data Lake Storage ソースをダブルクリックしてソースコンポーネントエディタを開きます。
  2. [Connection Manager]メニューで、以前作成した接続マネジャーを選択します。The Connection Manager to be used for the source component.(Salesforce is shown.)
  3. データの書き出しに使用するクエリを指定します。例: SELECT FullPath, Permission FROM Resources WHERE Type = 'FILE' The SQL query to retrieve records.(Salesforce is shown.)
  4. Azure Data Lake Storage Source コントロールを閉じて、ADO.NET Destination に接続します。

SQL Server Destination を構成する

以下のステップに従って、Azure Data Lake Storage をロードするSQL サーバーテーブルを指定します。

  1. ADO.NET Destination を選択して、新しい接続を追加します。接続するサーバーおよびデータベースの情報を入力。
  2. Data access モードメニューで、[table or view]を選択します。
  3. [Table Or View]メニューで、設定するテーブルまたはビューを選択します。
  4. [Mappings]画面で必要なプロパティを設定します。 The mappings from the SSIS source component to SQL Server.(Salesforce is shown.)

プロジェクトの実行

プロジェクトを実行できるようになりました。SSIS Task の実行が完了すると、データベースにAzure Data Lake Storage データが入力されます。

The completed import.(Salesforce is shown.)

トライアル・お問い合わせ

30日間無償トライアルで、CData のリアルタイムデータ連携をフルにお試しいただけます。記事や製品についてのご質問があればお気軽にお問い合わせください。