Cmdlets for Elasticsearch

Build 20.0.7654


Using a top-level document view of the Elasticsearch data provides ready access to top-level elements. The 本製品 returns nested elements in aggregate, as single columns.

One aspect to consider is performance. You forego the time and resources to process and parse nested elements -- the 本製品 parses the returned data once, using streaming to read the JSON data. Another consideration is your need to access any data stored in nested parent elements, and the ability of your tool or application to process JSON.

Modeling a Top-Level Document View

With DataModel set to "Document" (the default), the 本製品 scans only the top-level object by default. The top-level object elements are available as columns due to the default object flattening. Nested objects are returned as aggregated JSON.


Below is a sample query and the results, based on the sample document in 生データ. The query results in a single "insured" table.


The following query pulls the top-level object elements and the vehicles array into the results.

  [address.street] AS address_street,
  [] AS address_city,
  [address.state] AS address_state,


With a document view of the data, the address object is flattened into 3 columns (when FlattenObjects set to true) and the _id, name, insured_ages, and vehicles elements are returned as individual columns, resulting in a table with 7 columns.

1John SmithMain StreetChapel HillNC[ 17, 43, 45 ]
[{"year":2015,"make":"Dodge","model":"RAM 1500","body_style":"TK"},{"year":2015,"make":"Suzuki","model":"V-Strom 650 XT","body_style":"MC"},{"year":1992,"make":"Harley Davidson","model":"FXR","body_style":"MC"}]
2Joseph NewmanOak StreetRaleighNC[ 23, 25 ]

See Also

  • 自動スキーマ検出: Configure column discovery with horizontal flattening.
  • FreeForm;: Use dot notation to select nested data.
  • VerticalFlattening;: Access nested object arrays as separate tables.
  • JSON 関数: Manipulate the data returned to perform client-side aggregation and transformations.

Copyright (c) 2020 CData Software, Inc. - All rights reserved.
Build 20.0.7654