Skip to contents

Delta Sharing table handle

Delta Sharing table handle

Details

A cheap, reusable reference to a shared table. Metadata methods query the control plane without scanning rows. snapshot() and changes() create reader objects that carry query options and expose materializers. Downloaded files are cached for the R session and shared by handles for the same table.

Created via SharingClient$table(), not directly.

Predicate hints

Snapshot predicates are ordinary nested R lists. For example:

active_orders <- list(
  op = "equal",
  children = list(
    list(op = "column", name = "is_active", valueType = "bool"),
    list(op = "literal", value = "true", valueType = "bool")
  )
)
orders$snapshot(predicate = active_orders)

The sharing server treats the predicate as a best-effort hint, not an exact row filter.

Active bindings

cache_path

Read-only path to this table's session cache. Removing it manually invalidates active lazy readers; the next read recreates it.

Methods


Method new()

Create a table handle. Prefer SharingClient$table().

Usage

SharingTable$new(profile, auth, identifier, concurrency = 4L)

Arguments

profile

Parsed profile (internal).

auth

Authentication context (internal).

identifier

A list(share, schema, table) (internal).

concurrency

Maximum number of concurrent file downloads.


Method identifier()

The structured table identifier.

Usage

SharingTable$identifier()

Returns

A list with share, schema, and table.


Method version()

The current table version.

Usage

SharingTable$version()

Returns

A non-negative whole number.


Method protocol()

The table protocol capabilities.

Usage

SharingTable$protocol()

Returns

A safe list of protocol fields.


Method metadata()

The table metadata (no row scan).

Usage

SharingTable$metadata()

Returns

A safe structured metadata list.


Method schema()

The table's logical schema.

Usage

SharingTable$schema()

Returns

The parsed struct schema.


Method snapshot()

Configure a snapshot read.

Usage

SharingTable$snapshot(
  version = NULL,
  timestamp = NULL,
  columns = NULL,
  limit = NULL,
  predicate = NULL,
  response_format = "auto"
)

Arguments

version

Optional non-negative whole-number version.

timestamp

Optional scalar timestamp string or POSIXct value.

columns

Optional character vector of projected columns.

limit

Optional non-negative whole-number row limit.

predicate

Optional nested R list representing a structured server-side predicate hint. This is not an exact row filter.

response_format

One of "auto", "delta", or "parquet".

Returns

A SharingSnapshot.


Method changes()

Configure a change data feed read.

Usage

SharingTable$changes(
  starting_version = NULL,
  ending_version = NULL,
  starting_timestamp = NULL,
  ending_timestamp = NULL,
  columns = NULL
)

Arguments

starting_version, ending_version

Optional version bounds.

starting_timestamp, ending_timestamp

Optional timestamp strings or POSIXct bounds.

columns

Optional character vector of projected columns.

Returns

A SharingChanges.


Method print()

Print the table handle.

Usage

SharingTable$print(...)

Arguments

...

Ignored.