Get a list of tables
Returns a collection of tables accessible by the CAS server in the Caslib. Tables in this context refer to both loaded CAS tables as well as unloaded source tables. - For path-based caslibs, the source table shown will be the first matching .sashdat, .sas7bdat, .parquet, or .csv file found, in that order, independent of case. - For non-path-based caslibs (such as DBMS libraries), the source table used will be the first matching source table name found, independent of case. Supports SAS standard paging query parameters. Supports SAS standard paging query parameters, sorting, and filtering. Schema of items returned in the response collection is included below, and are of type application/vnd.sas.cas.table+json.
1{2 "links": [3 {4 "method": "GET",5 "rel": "up",6 "href": "/casManagement/servers/cas-shared-default/caslibs/Public/",7 "uri": "/casManagement/servers/cas-shared-default/caslibs/Public/",8 "type": "application/vnd.sas.cas.caslib"9 },10 {11 "method": "GET",12 "rel": "self",13 "href": "/casManagement/servers/cas-shared-default/caslibs/Public/tables?scope=all&caslibName=Public&excludeItemLinks=false&sourcesOnly=false&state=all&start=0&limit=2",14 "uri": "/casManagement/servers/cas-shared-default/caslibs/Public/tables?scope=all&caslibName=Public&excludeItemLinks=false&sourcesOnly=false&state=all&start=0&limit=2",15 "type": "application/vnd.sas.collection",16 "itemType": "application/vnd.sas.cas.table"17 },18 {19 "method": "GET",20 "rel": "collection",21 "href": "/casManagement/servers/cas-shared-default/caslibs/Public/tables",22 "uri": "/casManagement/servers/cas-shared-default/caslibs/Public/tables",23 "type": "application/vnd.sas.collection",24 "itemType": "application/vnd.sas.cas.table"25 },26 {27 "method": "GET",28 "rel": "next",29 "href": "/casManagement/servers/cas-shared-default/caslibs/Public/tables?scope=all&caslibName=Public&excludeItemLinks=false&sourcesOnly=false&state=all&start=2&limit=2",30 "uri": "/casManagement/servers/cas-shared-default/caslibs/Public/tables?scope=all&caslibName=Public&excludeItemLinks=false&sourcesOnly=false&state=all&start=2&limit=2",31 "type": "application/vnd.sas.collection"32 },33 {34 "method": "GET",35 "rel": "last",36 "href": "/casManagement/servers/cas-shared-default/caslibs/Public/tables?scope=all&caslibName=Public&excludeItemLinks=false&sourcesOnly=false&state=all&start=8&limit=2",37 "uri": "/casManagement/servers/cas-shared-default/caslibs/Public/tables?scope=all&caslibName=Public&excludeItemLinks=false&sourcesOnly=false&state=all&start=8&limit=2",38 "type": "application/vnd.sas.collection"39 },40 {41 "method": "POST",42 "rel": "upload",43 "href": "/casManagement/servers/cas-shared-default/caslibs/Public/tables",44 "uri": "/casManagement/servers/cas-shared-default/caslibs/Public/tables",45 "responseType": "application/vnd.sas.cas.table"46 }47 ],48 "name": "tables",49 "accept": "application/vnd.sas.cas.table",50 "count": 9,51 "items": [52 {53 "version": 1,54 "name": "CONTACTS",55 "tableReference": {56 "tableUri": "/dataTables/dataSources/cas~fs~cas-shared-default~fs~Public/tables/CONTACTS",57 "sessionId": "08863edb-02e0-7945-88e7-9f55ebc7a310",58 "sourceCaslibName": "Public",59 "sourceTableName": "Contacts.sashdat"60 },61 "scope": "global",62 "state": "loaded",63 "repeated": false,64 "created": "2017-09-15T20:38:06.549000Z",65 "lastModified": "2017-09-15T20:38:06.551000Z",66 "lastAccessed": "2017-09-15T20:38:06.550000Z",67 "createdBy": "userId",68 "rowCount": 3276,69 "columnCount": 12,70 "characterSet": "UTF8",71 "encoding": "utf-8",72 "serverName": "cas-shared-default",73 "caslibName": "Public",74 "disconnected": false,75 "attributes": {76 "owner": "userid",77 "size": 796288,78 "encryption": "NONE",79 "time": "15Sep2017:20:29:02",80 "group": "mygroup"81 },82 "links": [83 {84 "method": "GET",85 "rel": "up",86 "href": "/casManagement/servers/cas-shared-default/caslibs/Public/tables",87 "uri": "/casManagement/servers/cas-shared-default/caslibs/Public/tables",88 "type": "application/vnd.sas.collection",89 "itemType": "application/vnd.sas.cas.table"90 },91 {92 "method": "GET",93 "rel": "self",94 "href": "/casManagement/servers/cas-shared-default/caslibs/Public/tables/CONTACTS",95 "uri": "/casManagement/servers/cas-shared-default/caslibs/Public/tables/CONTACTS",96 "type": "application/vnd.sas.cas.table"97 },98 {99 "method": "POST",100 "rel": "save",101 "href": "/casManagement/servers/cas-shared-default/caslibs/Public/tables/CONTACTS",102 "uri": "/casManagement/servers/cas-shared-default/caslibs/Public/tables/CONTACTS",103 "type": "application/vnd.sas.cas.table.save.request",104 "responseType": "application/vnd.sas.cas.table"105 },106 {107 "method": "DELETE",108 "rel": "delete",109 "href": "/casManagement/servers/cas-shared-default/caslibs/Public/tables/CONTACTS",110 "uri": "/casManagement/servers/cas-shared-default/caslibs/Public/tables/CONTACTS"111 },112 {113 "method": "GET",114 "rel": "summaryStatistics",115 "href": "/casManagement/servers/cas-shared-default/caslibs/Public/tables/CONTACTS/summaryStatistics",116 "uri": "/casManagement/servers/cas-shared-default/caslibs/Public/tables/CONTACTS/summaryStatistics",117 "type": "application/vnd.sas.collection",118 "itemType": "application/vnd.sas.cas.column.summary.statistics"119 },120 {121 "method": "GET",122 "rel": "distinctCount",123 "href": "/casManagement/servers/cas-shared-default/caslibs/Public/tables/CONTACTS/distinctCount",124 "uri": "/casManagement/servers/cas-shared-default/caslibs/Public/tables/CONTACTS/distinctCount",125 "type": "application/vnd.sas.collection",126 "itemType": "application/vnd.sas.cas.column.summary.statistics"127 },128 {129 "method": "PUT",130 "rel": "updateScope",131 "href": "/casManagement/servers/cas-shared-default/caslibs/Public/tables/CONTACTS/scope",132 "uri": "/casManagement/servers/cas-shared-default/caslibs/Public/tables/CONTACTS/scope",133 "responseType": "application/json;text/plain"134 },135 {136 "method": "PUT",137 "rel": "updateState",138 "href": "/casManagement/servers/cas-shared-default/caslibs/Public/tables/CONTACTS/state",139 "uri": "/casManagement/servers/cas-shared-default/caslibs/Public/tables/CONTACTS/state",140 "responseType": "application/json;text/plain"141 },142 {143 "method": "GET",144 "rel": "columns",145 "href": "/casManagement/servers/cas-shared-default/caslibs/Public/tables/CONTACTS/columns",146 "uri": "/casManagement/servers/cas-shared-default/caslibs/Public/tables/CONTACTS/columns",147 "type": "application/vnd.sas.collection",148 "itemType": "application/vnd.sas.cas.column"149 },150 {151 "method": "GET",152 "rel": "dataTable",153 "href": "/dataTables/dataSources/cas~fs~cas-shared-default~fs~Public/tables/CONTACTS",154 "uri": "/dataTables/dataSources/cas~fs~cas-shared-default~fs~Public/tables/CONTACTS",155 "type": "application/vnd.sas.data.table"156 }157 ]158 },159 {160 "version": 1,161 "name": "MYDATA",162 "tableReference": {163 "tableUri": "/dataTables/dataSources/cas~fs~cas-shared-default~fs~Public/tables/MYDATA",164 "sessionId": "08863edb-02e0-7945-88e7-9f55ebc7a310",165 "sourceCaslibName": "Public",166 "sourceTableName": "mydata.sashdat"167 },168 "scope": "global",169 "state": "loaded",170 "repeated": false,171 "created": "2017-09-15T20:35:02.376000Z",172 "lastModified": "2017-09-15T20:35:02.377000Z",173 "lastAccessed": "2017-09-15T20:35:02.377000Z",174 "createdBy": "userId",175 "rowCount": 160,176 "columnCount": 9,177 "characterSet": "UTF8",178 "encoding": "utf-8",179 "serverName": "cas-shared-default",180 "caslibName": "Public",181 "disconnected": true,182 "attributes": {183 "owner": "userid",184 "size": 36928,185 "encryption": "NONE",186 "time": "15Sep2017:20:29:08",187 "group": "mygroup"188 },189 "links": [190 {191 "method": "GET",192 "rel": "up",193 "href": "/casManagement/servers/cas-shared-default/caslibs/Public/tables",194 "uri": "/casManagement/servers/cas-shared-default/caslibs/Public/tables",195 "type": "application/vnd.sas.collection",196 "itemType": "application/vnd.sas.cas.table"197 },198 {199 "method": "GET",200 "rel": "self",201 "href": "/casManagement/servers/cas-shared-default/caslibs/Public/tables/MYDATA",202 "uri": "/casManagement/servers/cas-shared-default/caslibs/Public/tables/MYDATA",203 "type": "application/vnd.sas.cas.table"204 },205 {206 "method": "POST",207 "rel": "save",208 "href": "/casManagement/servers/cas-shared-default/caslibs/Public/tables/MYDATA",209 "uri": "/casManagement/servers/cas-shared-default/caslibs/Public/tables/MYDATA",210 "type": "application/vnd.sas.cas.table.save.request",211 "responseType": "application/vnd.sas.cas.table"212 },213 {214 "method": "DELETE",215 "rel": "delete",216 "href": "/casManagement/servers/cas-shared-default/caslibs/Public/tables/MYDATA",217 "uri": "/casManagement/servers/cas-shared-default/caslibs/Public/tables/MYDATA"218 },219 {220 "method": "GET",221 "rel": "summaryStatistics",222 "href": "/casManagement/servers/cas-shared-default/caslibs/Public/tables/MYDATA/summaryStatistics",223 "uri": "/casManagement/servers/cas-shared-default/caslibs/Public/tables/MYDATA/summaryStatistics",224 "type": "application/vnd.sas.collection",225 "itemType": "application/vnd.sas.cas.column.summary.statistics"226 },227 {228 "method": "GET",229 "rel": "distinctCount",230 "href": "/casManagement/servers/cas-shared-default/caslibs/Public/tables/MYDATA/distinctCount",231 "uri": "/casManagement/servers/cas-shared-default/caslibs/Public/tables/MYDATA/distinctCount",232 "type": "application/vnd.sas.collection",233 "itemType": "application/vnd.sas.cas.column.summary.statistics"234 },235 {236 "method": "PUT",237 "rel": "updateScope",238 "href": "/casManagement/servers/cas-shared-default/caslibs/Public/tables/MYDATA/scope",239 "uri": "/casManagement/servers/cas-shared-default/caslibs/Public/tables/MYDATA/scope",240 "responseType": "application/json;text/plain"241 },242 {243 "method": "PUT",244 "rel": "updateState",245 "href": "/casManagement/servers/cas-shared-default/caslibs/Public/tables/MYDATA/state",246 "uri": "/casManagement/servers/cas-shared-default/caslibs/Public/tables/MYDATA/state",247 "responseType": "application/json;text/plain"248 },249 {250 "method": "GET",251 "rel": "columns",252 "href": "/casManagement/servers/cas-shared-default/caslibs/Public/tables/MYDATA/columns",253 "uri": "/casManagement/servers/cas-shared-default/caslibs/Public/tables/MYDATA/columns",254 "type": "application/vnd.sas.collection",255 "itemType": "application/vnd.sas.cas.column"256 },257 {258 "method": "GET",259 "rel": "dataTable",260 "href": "/dataTables/dataSources/cas~fs~cas-shared-default~fs~Public/tables/MYDATA",261 "uri": "/dataTables/dataSources/cas~fs~cas-shared-default~fs~Public/tables/MYDATA",262 "type": "application/vnd.sas.data.table"263 }264 ]265 }266 ],267 "version": 2268}
Name | Type | Required | Description |
---|---|---|---|
caslibName | string | true | The Caslib name for which tables are being requested. |
serverName | string | true | Server name for which tables are being requested. |
Name | Type | Required | Description |
---|---|---|---|
scope | string | false | Omitting this value includes tables of all scopes. Specifying a value here filters the results to tables that match a particular scope. Valid values include session and global. |
sessionId | string | false | Session ID (used when session-specific tables are also desired in results). |
state | string | false | Omitting this value includes both loaded and unloaded (source) tables in the result. Specifying a value here filters the results to tables that match a particular state. Valid values include loaded (loaded tables) and unloaded (unloaded tables). |
excludeItemLinks | boolean | false | Determines whether item links are excluded from results. Defaults to false. |
filter | string<filter-criteria> | false | Filter criteria for returned items. The valid filter fields are the first-level fields in each item. The supported functions are and, or, not, eq, lt, le, gt, ge, contains, startsWith, endsWith, and isNull. Some sample queries: Search by name: starting with filter=startsWith(name, 'CAS') Search by name: filter=eq(name, 'CASUSER') Search for multiple items: filter=in(name, 'CASUSER', 'Public') |
limit | integer | false | Maximum number of items to return in this page of results. The actual number of returned items can be less if the collection has been exhausted. Defaults to 10. |
sortBy | string<sort-criteria> | false | Sort returned items. The sort criteria supports the first-level fields in each item. Some sample sorts: Sort by ascending name: sortBy=name:ascending Sort by descending name: sortBy=name:descending The default sort is by name in ascending order. |
sourcesOnly | boolean | false | Determines whether source tables should be displayed. Defaults to false. |
start | integer | false | The starting index of the first item in a page. Defaults to 0. |
Status | Meaning | Description | ||
---|---|---|---|---|
200 | OK | The request succeeded. The list of tables for the requested CAS server, CAS library, and optional session was returned. | Schema | |
400 | Bad Request | The request was invalid. | Schema | |
404 | Not Found | The requested CAS server or Caslib does not exist. | ||
409 | Conflict | The request could not be completed due to a conflict with the current state of the resource. Details are included in the response body. |