Get a row set by the filter criteria

post/tables/{tableId}/rowSet

Returns a paginated collection of rows and their cell's corresponding columns. Standard paging options are provided. Sorting and filtering options are provider dependent, but the default sort order is ascending by row order (i.e. index). If the provider has naturally unordered row data, it must allow pagination in a consistent manner.

Request Samples

1

Response Samples

1{
2 "count": 6048,
3 "start": 0,
4 "limit": 10,
5 "columnDetail": "names",
6 "columnStart": 0,
7 "columnLimit": 25,
8 "rows": [
9 [
10 "Private flight",
11 "N",
12 "United States"
13 ],
14 [
15 "135 Airways",
16 "N",
17 "United States"
18 ],
19 [
20 "1Time Airline",
21 "N",
22 "South Africa"
23 ],
24 [
25 "2 Sqn No 1 Elementary Flying Training School",
26 "N",
27 "United Kingdom"
28 ],
29 [
30 "213 Flight Unit",
31 "N",
32 "Russia"
33 ],
34 [
35 "223 Flight Unit State Airline",
36 "N",
37 "Russia"
38 ],
39 [
40 "224th Flight Unit",
41 "N",
42 "Russia"
43 ],
44 [
45 "247 Jet Ltd",
46 "N",
47 "United Kingdom"
48 ],
49 [
50 "3D Aviation",
51 "N",
52 "United States"
53 ],
54 [
55 "40-Mile Air",
56 "N",
57 "United States"
58 ]
59 ],
60 "columns": [
61 "NAME",
62 "ALIAS",
63 "COUNTRY"
64 ],
65 "version": 1,
66 "links": [
67 {
68 "method": "GET",
69 "rel": "rowSet",
70 "uri": "/rowSets/tables/cas~fs~cas-shared-default~fs~MYCASLIB~fs~AIRLINES/rowSet",
71 "href": "/rowSets/tables/cas~fs~cas-shared-default~fs~MYCASLIB~fs~AIRLINES/rowSet",
72 "type": "application/vnd.sas.data.row.set"
73 },
74 {
75 "method": "GET",
76 "rel": "self",
77 "uri": "/rowSets/tables/cas~fs~cas-shared-default~fs~MYCASLIB~fs~AIRLINES/rowSet?start=0&limit=10&includeColumns=NAME,ALIAS,COUNTRY",
78 "href": "/rowSets/tables/cas~fs~cas-shared-default~fs~MYCASLIB~fs~AIRLINES/rowSet?start=0&limit=10&includeColumns=NAME,ALIAS,COUNTRY",
79 "type": "application/vnd.sas.data.row.set"
80 },
81 {
82 "method": "GET",
83 "rel": "first",
84 "uri": "/rowSets/tables/cas~fs~cas-shared-default~fs~MYCASLIB~fs~AIRLINES/rowSet?start=0&limit=10&includeColumns=NAME,ALIAS,COUNTRY",
85 "href": "/rowSets/tables/cas~fs~cas-shared-default~fs~MYCASLIB~fs~AIRLINES/rowSet?start=0&limit=10&includeColumns=NAME,ALIAS,COUNTRY",
86 "type": "application/vnd.sas.data.row.set"
87 },
88 {
89 "method": "GET",
90 "rel": "next",
91 "uri": "/rowSets/tables/cas~fs~cas-shared-default~fs~MYCASLIB~fs~AIRLINES/rowSet?start=10&limit=10&includeColumns=NAME,ALIAS,COUNTRY",
92 "href": "/rowSets/tables/cas~fs~cas-shared-default~fs~MYCASLIB~fs~AIRLINES/rowSet?start=10&limit=10&includeColumns=NAME,ALIAS,COUNTRY",
93 "type": "application/vnd.sas.data.row.set"
94 },
95 {
96 "method": "GET",
97 "rel": "last",
98 "uri": "/rowSets/tables/cas~fs~cas-shared-default~fs~MYCASLIB~fs~AIRLINES/rowSet?start=6040&limit=10&includeColumns=NAME,ALIAS,COUNTRY",
99 "href": "/rowSets/tables/cas~fs~cas-shared-default~fs~MYCASLIB~fs~AIRLINES/rowSet?start=6040&limit=10&includeColumns=NAME,ALIAS,COUNTRY",
100 "type": "application/vnd.sas.data.row.set"
101 },
102 {
103 "method": "GET",
104 "rel": "up",
105 "uri": "/dataTables/dataSources/cas~fs~cas-shared-default~fs~MYCASLIB/tables/AIRLINES",
106 "href": "/dataTables/dataSources/cas~fs~cas-shared-default~fs~MYCASLIB/tables/AIRLINES",
107 "type": "application/vnd.sas.data.table"
108 }
109 ]
110}

Path Parameters

NameTypeRequiredDescription
tableId
string
true

The ID of the table. Its format is 'providerIdfssourceIdfslibraryNamefstableName'. The format is a tilda-encoded form composed of the following:

  • providerId: name of the provider. Examples: cas, Compute Use GET /dataSources/providers to see the list of available providers.
  • sourceId: refers to server id in case of cas and computeContextId in case of compute. An example sourceId for cas is cas-shared-default. An example sourceId for Compute is 97751fe6-8313-487f-865a-f941c8a75f8f (SAS Studio Compute Context). Use GET /dataSources/providers/{providerId}/sources to see the list of available sources.
  • libraryName: name of the library. Use GET /dataSources/providers/{providerId}/sources/{sourceId}/children to see the list of available libraries.
  • tableName: name of the table. Use GET /dataTables/dataSources/{dataSourceId}/tables to see the list of available tables in a library. An example tableId for cas is 'casfscas-shared-defaultfsmodelsfscars'. An example tableId for Compute is 'Computefs97751fe6-8313-487f-865a-f941c8a75f8ffscat-compfscars'.

Query Parameters

NameTypeRequiredDescription
columnDetail
string
false

The desired column representation. The columnDetail options listed below yield the following in the columns member.

  • summary - application/vnd.sas.data.column.summary
  • detail - application/vnd.sas.data.column
  • names - the column name as a string If no value is specified, the default value is 'summary'.
Allowed values:
summarydetailnames
columnLimit
integer
false

Maximum number of cells per row and columns to return in this page of results. The number of returned columns might be less if the collection has been exhausted. Defaults to 25.

columnSortBy
string<sort-criteria>
false

The sorting criteria for returned columns and cells of data. The columns can be sorted by any valid column name. The default sort order is ascending by column index. Some sample sorts: Examples:

  • Sort descending by column index descending: /rowSets/tables/{tableId}/rowSet?columnSortBy=index:descending
  • Sort ascending by column name ascending: /rowSets/tables/{tableId}/rowSet?columnSortBy=name:ascending
columnStart
integer
false

The starting index of the first column in a page. The default value is "0".

format
boolean
false

Whether or not to format the cells of data. Defaults to true.

includeColumns
string
false

Includes the row index as the first item in the row data. The default value is "false".

limit
integer<int32>
false

Pagination parameter, which specifies how many items to return.

Default:
10
preserveSession
boolean
false

This parameter has effect only if the sessionId query parameter is not specified. If this is set to true and no sessionId is provided, the session created by the data service provider is not destroyed. All returned links except the "self" link have the sessionId query parameter added to their respective URIs. Also, they contain an additional session link to the application/vnd.sas.data.session resource that corresponds to the provided sessionId. If set to false or not specified, the session will be destroyed after the request is complete. Defaults to false.

sessionId
string
false

The unique identifier of the session used to access the data service provider's backing service. When this is not specified the data service provider will create a temporary session, and then destroy it after the request is complete. If this is specified all returned links, except the "self" link, will have the sessionId query parameter added to their respective URIs. Also, they will contain an additional session link to the application/vnd.sas.data.session resource that corresponds to the provided sessionId.

sortBy
string<sort-criteria>
false

The sorting criteria for returned rows of data. The rows can be sorted by any valid column name. The default sort order is ascending by row order (i.e. index). Some sample sorts: Examples:

  • Sort ascending by column with name COLUMN_A: /rowSets/tables/{tableId}/rowSet?sortBy=COLUMN_A:ascending
  • Sort descending by column with name COLUMN_A: /rowSets/tables/{tableId}/rowSet?sortBy=COLUMN_A:descending
start
integer<int32>
false

Pagination parameter, which specifies the starting index.

Default:
0

Request Body

The WHERE clause to pass through to the underlying data service. This parameter acts as a filter on the provided data.

The WHERE clause to pass through to the underlying data service. This acts as a filter on the provided data. example: Make='Honda'.

Responses

StatusMeaningDescription
200OK

The request succeeded.

Schema
400Bad Request

The request was invalid. An invalid request was made in one of the following scenarios:

  • A negative start value is provided.
  • A negative limit value is provided.
  • A non-existent column is specified in the sortBy or includeColumns parameter.
  • An invalid value is specified in a parameter (such as columnDetail=doesNotExist).
Schema
404Not Found

No resource exists at the requested path. The table that is associated with these rows does not exist.

Schema