{"templateId":"markdown","sharedDataIds":{"sidebar":"sidebar-@l10n/ja/sidebars.yaml"},"props":{"metadata":{"markdoc":{"tagList":["img","admonition"]},"type":"markdown"},"seo":{"title":"Data Tank 2.0とPlazma DBの統合について","description":"PostgreSQL インポート/エクスポートコネクターとPrestoクエリ統合を使用して、Treasure Data Data Tank 2.0とPlazma DBを統合する方法について説明します。","siteUrl":"https://docs.treasuredata.com","lang":"en-US","llmstxt":{"hide":false,"sections":[{"title":"Table of contents","includeFiles":["**/*"],"excludeFiles":[]}],"excludeFiles":[]}},"dynamicMarkdocComponents":[],"compilationErrors":[],"ast":{"$$mdtype":"Tag","name":"article","attributes":{},"children":[{"$$mdtype":"Tag","name":"Heading","attributes":{"level":1,"id":"data-tank-20とplazma-dbの統合について","__idx":0},"children":["Data Tank 2.0とPlazma DBの統合について"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Treasure Data Data Tank 2.0では、PostgreSQLインポート/エクスポートコネクターを使用してPlazma DBと統合することができます。"]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"data-tank-20からplazma-dbへのデータインポート","__idx":1},"children":["Data Tank 2.0からPlazma DBへのデータインポート"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["PostgreSQLインポートコネクターを使用して、Data Tank 2.0からPlazma DBにデータをインポートできます。"]},{"$$mdtype":"Tag","name":"ol","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":["Data Tank 2.0 Management UIで、Data Tank 2.0のホスト名、ポート、データベース名を確認します。"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["アクセスキーを作成し、ユーザー名とパスワードを記録します。詳細については、",{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"https://docs.treasuredata.com/smart/project-integrations/postgresql-import-integration"},"children":["PostgreSQL Import Integration"]},"を参照してください。"]}]},{"$$mdtype":"Tag","name":"Image","attributes":{"src":"/assets/image2022-5-26_12-11-18.6a7e8e37c4ebdc5c043bfe7549a7b13549d57570f48d6df66944aed20e0c2e72.f97e5221.png","alt":"ホスト名、ポート、データベース名が表示されたData Tank 2.0 Management UI","withLightbox":true},"children":[]},{"$$mdtype":"Tag","name":"ol","attributes":{"start":3},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Authentication"]},"で、Data Tank 2.0のホスト名、ポート、データベース名、ユーザー名、パスワードを入力します。",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Use SSL"]},"オプションを有効にする必要があります。"]}]},{"$$mdtype":"Tag","name":"Image","attributes":{"src":"/assets/image2022-5-26_12-11-44.ad0a3671dc9f465d67056ef6c6e8c9c6b73e1614aaf08252e7c507031bfbf274.f97e5221.png","alt":"PostgreSQLインポートコネクターのAuthentication設定","withLightbox":true},"children":[]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"plazma-dbからdata-tank-20へのデータエクスポート","__idx":2},"children":["Plazma DBからData Tank 2.0へのデータエクスポート"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Result ExportとTreasure ワークフローを使用して、Plazma DBからData Tank 2.0にデータをコピーできます。"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["事前にData Tank 2.0 Management UIから、Data Tank 2.0のホスト名、ポート、データベース名を作成してください。また、",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["CUSTOMIZABLE_ADMIN"]},"ポリシーを持つアクセスキーを作成し、ユーザー名とパスワードを記録してください。Integrationを使用する際は、",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Set Role"]},"オプションの設定が必要です。"]},{"$$mdtype":"Tag","name":"Image","attributes":{"src":"/assets/image2022-5-26_12-12-14.8a139e02825112e1f9235d3544227dde2098b755df5843b2016d87c4883ddb47.f97e5221.png","alt":"Data Tank 2.0のエクスポート設定","withLightbox":true},"children":[]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"presto-data-tank-20-integration","__idx":3},"children":["Presto Data Tank 2.0 Integration"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["この機能は、お客様とTreasure Data双方での設定が必要です。"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Treasure Dataのクエリエンジンの1つであるPrestoを使用して、Data Tank 2.0に対してクエリを送信し、結果を取得できます。クエリの結果セットは、Prestoジョブ処理中にPlazma DBのデータとJOINすることができます。Prestoを使用する場合、クエリ構文はPrestoに準拠します（Data Tank 2.0の拡張機能はサポートされません）。クエリが送信されると、Data Tank 2.0への接続はReaderノードに対して行われるため、Writerノードへの負荷の影響を回避できます。"]},{"$$mdtype":"Tag","name":"Image","attributes":{"src":"/assets/image2022-5-31_16-40-29.e27798fd5f993944cf95486fa3ff18939faac40ebd43eb90fa4f7aea90ca14d3.f97e5221.png","alt":"Presto Data Tank 2.0統合アーキテクチャ","withLightbox":true},"children":[]},{"$$mdtype":"Tag","name":"Admonition","attributes":{"type":"info"},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Data Tank 2.0のアクセスキーとAPIを連携する設定は、Treasure Dataが操作します。"]}]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"操作手順","__idx":4},"children":["操作手順"]},{"$$mdtype":"Tag","name":"ol","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":["この機能で使用するData Tank 2.0のアクセスキーを作成します。Management UIでアクセスキーに必要なアクセスポリシーを設定します。"]},{"$$mdtype":"Tag","name":"Image","attributes":{"src":"/assets/image2022-5-26_12-13-6.9deb77b20322e758be66b54ff87ca16bff226c76746f658ebb4844de0cca5b7b.f97e5221.png","alt":"Data Tank 2.0 Management UIでのアクセスキーの作成","withLightbox":true},"children":[]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Treasure コンソールで、この機能専用の空のデータベースを作成します。"]},{"$$mdtype":"Tag","name":"Image","attributes":{"src":"/assets/image2022-5-26_12-13-28.a0ee06aa625085676fb36e6442bcff7c51e86312e675829246f7c0237bed0034.f97e5221.png","alt":"Treasure コンソールでの空のデータベースの作成","withLightbox":true},"children":[]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Treasure サポートに、Data Tank 2.0 Presto Integrationの有効化をリクエストします。リクエストには以下の情報を含めてください。"]},{"$$mdtype":"Tag","name":"ul","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":["手順1で作成したData Tank 2.0のアクセスキーとパスワード"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["手順2で作成したデータベース名"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["Data Tank 2.0のホスト名"]}]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Treasure Dataが統合設定を行い、完了次第お客様に報告します。"]}]}]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"クエリ構文","__idx":5},"children":["クエリ構文"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Presto経由でData Tank 2.0にアクセスするには、以下の構文を使用します。"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"sql","header":{"controls":{"copy":{}}},"source":"SELECT\n  [Data Tank 2.0のカラム名]\nFROM\n  [手順2で作成したデータベース名].[Data Tank 2.0のスキーマ名].[Data Tank 2.0のテーブル名]\n","lang":"sql"},"children":[]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"アクセス制御","__idx":6},"children":["アクセス制御"]},{"$$mdtype":"Tag","name":"ul","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Plazma DBの権限"]}," — Data Tank 2.0 Presto Integrationでは、Treasure Dataユーザーがデータベースに対してQueryまたはFull Accessの権限を持っている必要があります。アクセス制御はTreasure コンソールで管理されます。"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Data Tank 2.0の権限"]}," — Data Tank 2.0 Presto Integrationでは、Data Tank 2.0のアクセスキーに関連付けられたスキーマへのアクセス権限が必要です。アクセス制御はManagement UIで管理されます。"]}]},{"$$mdtype":"Tag","name":"Image","attributes":{"src":"/assets/image2022-5-31_18-34-55.c28fd8d65dc51379eeadb67648acee02097d18f757704f7250ecbc30a97e74d9.f97e5221.png","alt":"Data Tank 2.0 Presto Integrationのアクセス制御設定","withLightbox":true},"children":[]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"data-tank-20へのアクセス","__idx":7},"children":["Data Tank 2.0へのアクセス"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Data Tank 2.0はPostgreSQLプロトコルを提供しており、一般的なPostgreSQLクライアントツールを使用することができます。このセクションでは、",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["psql"]},"コマンドを使用してData Tank 2.0にアクセスする方法について説明します。"]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"psqlコマンドからのアクセス","__idx":8},"children":["psqlコマンドからのアクセス"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["psql"]},"コマンドを使用すると、CLIからData Tank 2.0に接続できます。"]},{"$$mdtype":"Tag","name":"ol","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"https://www.postgresql.org/download/"},"children":["PostgreSQLダウンロードページ"]},"から",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["psql"]},"をダウンロードしてインストールします。"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":["インストール後、以下のコマンドを実行します。"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"bash","header":{"controls":{"copy":{}}},"source":"psql -d <Database> -h <Host> -p 5432 -U <UserName>\n","lang":"bash"},"children":[]}]}]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["ユーザー名とパスワードは、Management UIの",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Access Key"]},"ページに表示されます。"]}]},"headings":[{"value":"Data Tank 2.0とPlazma DBの統合について","id":"data-tank-20とplazma-dbの統合について","depth":1},{"value":"Data Tank 2.0からPlazma DBへのデータインポート","id":"data-tank-20からplazma-dbへのデータインポート","depth":2},{"value":"Plazma DBからData Tank 2.0へのデータエクスポート","id":"plazma-dbからdata-tank-20へのデータエクスポート","depth":2},{"value":"Presto Data Tank 2.0 Integration","id":"presto-data-tank-20-integration","depth":2},{"value":"操作手順","id":"操作手順","depth":2},{"value":"クエリ構文","id":"クエリ構文","depth":2},{"value":"アクセス制御","id":"アクセス制御","depth":2},{"value":"Data Tank 2.0へのアクセス","id":"data-tank-20へのアクセス","depth":2},{"value":"psqlコマンドからのアクセス","id":"psqlコマンドからのアクセス","depth":3}],"frontmatter":{"seo":{"title":"Data Tank 2.0とPlazma DBの統合について","description":"PostgreSQL インポート/エクスポートコネクターとPrestoクエリ統合を使用して、Treasure Data Data Tank 2.0とPlazma DBを統合する方法について説明します。"}},"lastModified":"2026-06-01T09:47:58.000Z","pagePropGetterError":{"message":"","name":""}},"slug":"/ja/products/control-panel/datatank/about-integrating-data-tank-2-0-with-plazma-db","userData":{"isAuthenticated":false,"teams":["anonymous"]},"isPublic":true}