{"templateId":"markdown","sharedDataIds":{"sidebar":"sidebar-@l10n/ja/sidebars.yaml"},"props":{"metadata":{"markdoc":{"tagList":["admonition"]},"type":"markdown"},"seo":{"title":"クエリについて","description":"Treasure Data Product Documentation · Collect and Unify · Segment and Activate · Experiment and Analyze · Decisioning Automate with AI Scale and Trust.","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":"クエリについて","__idx":0},"children":["クエリについて"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Treasure Dataは、SQLコマンドを使用する2つのクエリエンジンと、企業が定義した属性および動作フィルターを使用してデータをフィルタリングできる事前定義されたクエリインターフェースを使用しています。これらはすべてTreasure コンソールで利用できます。2つのクエリエンジンはTrinoとHiveで、これらのクエリエディターはData Workbenchの「Queries」にあります。事前定義されたクエリインターフェースは、Audience Studioの「Master Segments」にあります。"]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"treasure-dataのクエリ","__idx":1},"children":["Treasure Dataのクエリ"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Treasure Dataでは、クエリを使用して、組織がアクセスできるさまざまなファーストパーティ、セカンドパーティ、サードパーティのデータソースから、顧客の行動についての定期的なインサイトを得ることができます。定期的にスケジュールされたクエリを作成して、定期的に特定の情報を更新したり、顧客の特定時点のスナップショットを提供するクエリを作成したりできます。"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["以下のインターフェースからクエリを実行できます:"]},{"$$mdtype":"Tag","name":"ul","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":["Treasure コンソール"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["API"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["JDBC/ODBC"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["スケジュールされたクエリ"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["ホストされたワークフロー実行フレームワーク"]}]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["すべてのクエリはジョブとして管理され、各ジョブに対してクエリエンジンを指定できます。"]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"クエリエンジンとしてのtrino","__idx":2},"children":["クエリエンジンとしてのTrino"]},{"$$mdtype":"Tag","name":"Admonition","attributes":{"type":"warning","name":"Info"},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Trinoクエリエンジンは、2021年のリブランディング以前はPrestoSQLまたは単にPrestoとして知られていました。Treasure Dataは以前のバージョンのPrestoをいくつかサポートしていました。新しいバージョンのPrestoは現在Trinoブランディングでサポートされており、",{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"/ja/products/customer-data-platform/data-workbench/queries/trino/trino-423"},"children":["Trino 423"]},"のサポートが導入されています。当面の間、Treasure Dataのドキュメントでは、PrestoとTrinoの両方が使用されます。新しい機能や機能はTrinoとして識別されます。ただし、PrestoとTrinoの両方に共通する既存の機能については、引き続きPrestoとして識別されます。"]}]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Trinoは、データ探索に役立つ短いインタラクティブクエリ向けに設計されています。業界標準のANSI SQL方言を使用しています。"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Hiveよりも優れたリアルタイム結果を提供しますが、大量のデータの処理では高いレイテンシがあります。さらに、メモリ容量にいくつかの制限があるため、クエリするデータがそのメモリ容量を超えると、クエリは失敗します。同時に、Hiveよりも10〜30倍高速にクエリを処理します。"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["では、Trinoをいつ使用するのでしょうか？"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["小規模から中規模のクエリがあり、特定のアドホックまたは探索的なクエリの即時結果が必要な場合です。"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Trinoの詳細については、",{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"/ja/products/customer-data-platform/data-workbench/queries/trino/quickstart"},"children":["Trinoクエリエンジンについて"]},"を参照してください。"]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"クエリエンジンとしてのhive","__idx":3},"children":["クエリエンジンとしてのHive"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Hiveは、バッチ処理と定期的にスケジュールされたクエリに適しています。大量のデータに関しては、クエリレイテンシが低いですが、処理時間が遅いため、小規模なアドホッククエリや探索的クエリには適していません。Hiveは、99.9%の確率で最後まで実行されることが重要なクエリに適しています。これは、より高い耐障害性を持ち、エラーが発生してもクエリ全体を再実行する必要がないためです。HiveはHiveQLと呼ばれるSQL言語の方言を使用しています。HiveQLには、特に多数のテーブルをクエリするユースケースに役立つ多くの優れた機能がありますが、Trinoほど完全で馴染みのある機能セットはありません。"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["では、Hiveをいつ使用するのでしょうか？"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["大規模なクエリがあり、即時結果が必要ない場合、および定期的にスケジュールされたクエリがある場合です。"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Hiveの詳細については、",{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"/ja/products/customer-data-platform/data-workbench/queries/hive/quickstart"},"children":["Hiveクエリエンジンについて"]},"を参照してください。"]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"trinoとhiveの特性とユースケース","__idx":4},"children":["TrinoとHiveの特性とユースケース"]},{"$$mdtype":"Tag","name":"ul","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Trino"]}," : Trinoは高速でインタラクティブなクエリ向けに設計されています。Trinoはレイテンシに最適化されています。その実行モデルはプッシュモデルと呼ばれます。"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Hive"]}," : オープンソースのHadoopプラットフォームにおける大規模データシステムのクエリ用に設計されています。Hive 2023.1はSQL風のクエリをTezジョブに変換し、非常に大量のデータの実行と処理を容易にします。Hiveはクエリのスループットに最適化されています。その実行モデルはプルモデルと呼ばれます。"]}]}]},{"$$mdtype":"Tag","name":"div","attributes":{"className":"md-table-wrapper"},"children":[{"$$mdtype":"Tag","name":"table","attributes":{"className":"md"},"children":[{"$$mdtype":"Tag","name":"thead","attributes":{},"children":[{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"th","attributes":{"data-label":""},"children":[]},{"$$mdtype":"Tag","name":"th","attributes":{"data-label":"Trino"},"children":["Trino"]},{"$$mdtype":"Tag","name":"th","attributes":{"data-label":"Hive"},"children":["Hive"]}]}]},{"$$mdtype":"Tag","name":"tbody","attributes":{},"children":[{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":["最適化対象"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["インタラクティビティ"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["スループット"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":["SQL標準化の忠実性"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["ANSI SQLに準拠するように設計されている"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["HiveQL (一般的なデータウェアハウスSQLのサブセット)"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":["大規模JOIN"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["スタースキーマジョイン (1つの大きなファクトテーブルと多数の小さなディメンションテーブル) に最適化"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["大規模なファクト間ジョインに非常に優れている"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":["最大クエリ長"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["1MB"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["ハードリミットなし"]}]}]}]}]}]},"headings":[{"value":"クエリについて","id":"クエリについて","depth":1},{"value":"Treasure Dataのクエリ","id":"treasure-dataのクエリ","depth":2},{"value":"クエリエンジンとしてのTrino","id":"クエリエンジンとしてのtrino","depth":2},{"value":"クエリエンジンとしてのHive","id":"クエリエンジンとしてのhive","depth":2},{"value":"TrinoとHiveの特性とユースケース","id":"trinoとhiveの特性とユースケース","depth":2}],"frontmatter":{"seo":{"title":"クエリについて"}},"lastModified":"2026-06-01T09:34:27.000Z","pagePropGetterError":{"message":"","name":""}},"slug":"/ja/products/customer-data-platform/data-workbench/queries","userData":{"isAuthenticated":false,"teams":["anonymous"]},"isPublic":true}