Gets the content of a dataset as a table in the specified format.
This endpoint currently does not support views (virtual datasets composed of other datasets).
Third-party applications using this endpoint via OAuth2 must request the following operation scope: api:datasets-read
.
string
The name of the Branch.
string
The Resource Identifier (RID) of the start Transaction.
string
The Resource Identifier (RID) of the end Transaction.
string
(enum)The export format. Must be ARROW
or CSV
.
Enum values: ARROW
, CSV
list<string>
A subset of the dataset columns to include in the result. Defaults to all columns.
integer
A limit on the number of rows to return. Note that row ordering is non-deterministic.
1
2
3
curl \
-H "Authorization: Bearer $TOKEN" \
"https://$HOSTNAME/api/v2/datasets/ri.foundry.main.dataset.c26f11c8-cdb3-4f44-9f5d-9816ea1c82da/readTable?branchName=master&startTransactionRid=ri.foundry.main.transaction.0a0207cb-26b7-415b-bc80-66a3aa3933f4&endTransactionRid=ri.foundry.main.transaction.0a0207cb-26b7-415b-bc80-66a3aa3933f4&format=CSV&columns=%5B%22id%22%2C%22firstName%22%2C%22lastName%22%5D"
Error Name | ||
---|---|---|
Read | Error Code | PERMISSION_DENIED |
Status Code | 403 | |
Description | The provided token does not have permission to read the given dataset as a table. | |
Parameters | datasetRid | |
Schema | Error Code | NOT_FOUND |
Status Code | 404 | |
Description | A schema could not be found for the given dataset and branch, or the client token does not have access to it. | |
Parameters | datasetRid, branchName, transactionRid | |
Column | Error Code | INVALID_ARGUMENT |
Status Code | 400 | |
Description | The dataset contains column types that are not supported. | |
Parameters | datasetRid | |
Read | Error Code | PERMISSION_DENIED |
Status Code | 403 | |
Description | Could not readTable the Dataset. | |
Parameters | datasetRid |
See Errors for a general overview of errors in the platform.