compute: Force execution of an Impala query

computeR Documentation

Force execution of an Impala query

Description

compute()

Executes the query and stores the result in a new Impala table

collect()

Executes the query and returns the result to R as a data frame tbl

collapse()

Generates the query for later execution

Usage

## S3 method for class 'tbl_impala'
compute(
  x,
  name,
  temporary = TRUE,
  unique_indexes = NULL,
  indexes = NULL,
  analyze = FALSE,
  external = FALSE,
  overwrite = FALSE,
  force = FALSE,
  field_terminator = NULL,
  line_terminator = NULL,
  file_format = NULL,
  ...
)

## S3 method for class 'tbl_impala'
collect(x, ..., n = Inf, warn_incomplete = TRUE)

## S3 method for class 'tbl_impala'
collapse(x, vars = NULL, ...)

Arguments

x

an object with class tbl_impala

name

the name for the new Impala table

temporary

must be set to FALSE

unique_indexes

not used

indexes

not used

analyze

whether to run COMPUTE STATS after adding data to the new table

external

whether the new table will be externally managed

overwrite

whether to overwrite existing table data (currently ignored)

force

whether to silently fail if the table already exists

field_terminator

the deliminter to use between fields in text file data. Defaults to the ASCII control-A (hex 01) character

line_terminator

the line terminator. Defaults to "\n"

file_format

the storage format to use. Options are "TEXTFILE" (default) and "PARQUET"

...

other arguments passed on to methods

n

the number of rows to return

warn_incomplete

whether to issue a warning if not all rows retrieved

vars

not used

Note

Impala does not support temporary tables. When using compute() to store results in an Impala table, you must set temporary = FALSE.


implyr documentation built on May 29, 2024, 8 a.m.