Mirrors batch.submit_job. Batch jobs are the way to request slices too
large to stream with db_get_range() — Databento recommends them above
about five gigabytes. Submit the job, poll it with db_batch_list_jobs(),
then fetch the output with db_batch_download().
Usage
db_batch_submit_job(
dataset,
symbols,
schema,
start,
end = NULL,
encoding = "dbn",
compression = "zstd",
pretty_px = FALSE,
pretty_ts = FALSE,
map_symbols = NULL,
split_symbols = FALSE,
split_duration = "day",
split_size = NULL,
delivery = "download",
stype_in = "raw_symbol",
stype_out = "instrument_id",
limit = NULL
)Arguments
- dataset
Dataset code, e.g.
"GLBX.MDP3".- symbols
Character vector of symbols, a single comma-separated string, or
NULLfor all symbols. Withstype_in = "instrument_id"a numeric vector is accepted. At most 2000 symbols per request.- schema
Schema name, see
db_schemas().- start, end
Request window, start inclusive and end exclusive. A string passes through verbatim, a
Datebecomes a plain date, aPOSIXctan ISO-8601 UTC instant, and a number is read as nanoseconds since the UNIX epoch. LeavingendasNULLasks the server to forward-fill fromstart.- encoding
Output encoding, see
db_encodings().- compression
Output compression, see
db_compressions().- pretty_px
Write decimal prices instead of fixed-point integers.
- pretty_ts
Write ISO-8601 timestamps instead of nanosecond counts.
- map_symbols
Append a
symbolfield to every record.NULL, the default, meansTRUEfor the text encodings andFALSEfor DBN.- split_symbols
Split the output into one file per symbol.
- split_duration
Split the output by
"day","week","month","year"or"none".- split_size
Optional maximum size per output file, in bytes.
- delivery
Delivery mechanism;
"download"is the only one offered.- stype_in
Symbol type of
symbols, seedb_stypes(). Use"parent"for product-level symbols such as"ES.FUT"or"SPX.OPT".- stype_out
Symbol type of the output, see
db_stypes().- limit
Optional cap on the number of records.
Details
Defaults follow the Python client, so encoding is "dbn". Note that
databentoR can read back only the "csv" and "json" encodings; a DBN job
downloads fine but needs a DBN decoder to open.
