Enum Format
- java.lang.Object
-
- java.lang.Enum<Format>
-
- com.databricks.sdk.service.sql.Format
-
- All Implemented Interfaces:
Serializable
,Comparable<Format>
@Generated public enum Format extends Enum<Format>
Statement execution supports two result formats: `JSON_ARRAY` (default), and `ARROW_STREAM`.**NOTE**
Currently `JSON_ARRAY` is only available for requests with `disposition=INLINE`, and `ARROW_STREAM` is only available for requests with `disposition=EXTERNAL_LINKS`.
When specifying `format=JSON_ARRAY`, result data will be formatted as an array of arrays of values, where each value is either the *string representation* of a value, or `null`. For example, the output of `SELECT concat('id-', id) AS strId, id AS intId FROM range(3)` would look like this:
``` [ [ "id-1", "1" ], [ "id-2", "2" ], [ "id-3", "3" ], ] ```
`INLINE` `JSON_ARRAY` data can be found within `StatementResponse.result.chunk.data_array` or `ResultData.chunk.data_array`.
When specifying `format=ARROW_STREAM`, results fetched through `external_links` will be chunks of result data, formatted as Apache Arrow Stream. See [Apache Arrow Streaming Format] for more details.
[Apache Arrow Streaming Format]: https://arrow.apache.org/docs/format/Columnar.html#ipc-streaming-format
-
-
Enum Constant Summary
Enum Constants Enum Constant Description ARROW_STREAM
JSON_ARRAY
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static Format
valueOf(String name)
Returns the enum constant of this type with the specified name.static Format[]
values()
Returns an array containing the constants of this enum type, in the order they are declared.
-
-
-
Method Detail
-
values
public static Format[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:for (Format c : Format.values()) System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
public static Format valueOf(String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)- Parameters:
name
- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException
- if this enum type has no constant with the specified nameNullPointerException
- if the argument is null
-
-