参数 | 类型 | 描述 |
---|---|---|
apiKey | string | 你的 API key, 用于身份验证. 必填. |
name | string | 指定数据表格名称. 选填. |
https://api.esv2.com/v2/Api/DataTablesGetTables?apiKey=YOUR_API_KEY_HEREhttps://api.esv2.com/v2/Api/DataTablesGetTables?apiKey=YOUR_API_KEY_HERE&name=TABLE_NAME |
应答Table元素 (如果请求中没有指定表格名称):
元素/属性 | 类型 | 描述 |
---|---|---|
Id | int | 数据表格ID. |
Name | string | 数据表格名称. |
ColumnsCount | int | 数据表格中的列数. |
RelationshipsCount | int | 以数据表格作为源的数据关系数 |
RelationshipsDestinationCount | int | 以数据表格作为目标的数据关系数 |
Rows | int | 数据表格中的数据条目数 |
Size | int | 以MB计的数据表格大小 |
HTTP/1.1 200 OK
Cache-Control: private
Content-Type: text/xml; charset=utf-8
Server: Microsoft-IIS/7.5
X-AspNetMvc-Version: 3.0
X-AspNet-Version: 4.0.30319
X-Powered-By: ASP.NET
Date: Mon, 10 Jun 2013 16:02:49 GMT
Content-Length: 320
<ApiResponse xmlns:xsd=”http://www.w3.org/2001/XMLSchema” xmlns:xsi=”http://www.w3.org/2001/XMLSchema-instance”>
<TableList>
<Tables>
<Table>
<Id>1</Id>
<Name>Table1</Name>
<ColumnsCount>8</ColumnsCount>
<RelationshipsCount>0</RelationshipsCount>
<RelationshipsDestinationCount>1</RelationshipsDestinationCount>
<Rows>5</Rows>
<Size>0.05</Size>
</Table>
</Tables>
</TableList>
</ApiResponse>
|
元素/属性 | 类型 | 描述 |
---|---|---|
Id | int | 数据表格ID. |
Name | string | 数据表格名称. |
ColumnsCount | int | 数据表格中的列数. |
RelationshipsCount | int | 以数据表格作为源的数据关系数 |
RelationshipsDestinationCount | int | 以数据表格作为目标的数据关系数 |
Rows | int | 数据表格中的数据条目数 |
Columns | complex | 各个列的信息集合 (TableColumn元素). |
TableColumn (Columns的子元素) 子元素:
元素/属性 | 类型 | 描述 |
---|---|---|
Name | string | 列的名称 |
ColumnsType | string | 列的数据类型 |
Length | int | string 类型列数据的长度. |
DefaultValue | string | 列空集的默认值. |
IsPrimaryKey | boolean | 如果该列是主键的一部分,填写”true”.否则忽略 |
IsRequired | boolean | 如果该列为必填项,填写”true”.否则忽略 |
HTTP/1.1 200 OK
Cache-Control: private
Content-Type: text/xml; charset=utf-8
Server: Microsoft-IIS/7.5
X-AspNetMvc-Version: 3.0
X-AspNet-Version: 4.0.30319
X-Powered-By: ASP.NET
Date: Mon, 10 Jun 2013 16:01:58 GMT
Content-Length: 1826
<ApiResponse xmlns:xsd=”http://www.w3.org/2001/XMLSchema” xmlns:xsi=”http://www.w3.org/2001/XMLSchema-instance”>
<Details>
<Id>1</Id>
<Name>Table1</Name>
<ColumnsCount>0</ColumnsCount>
<RelationshipsCount>0</RelationshipsCount>
<RelationshipsDestinationCount>0</RelationshipsDestinationCount>
<Rows>0</Rows>
<Description>Table1 description</Description>
<Columns>
<TableColumn>
<Name>Column1</Name>
<ColumnType>String</ColumnType>
<Length>4000</Length>
<DefaultValue>test</DefaultValue>
<IsPrimaryKey>true</IsPrimaryKey>
</TableColumn>
<TableColumn>
<Name>Column2</Name>
<ColumnType>Number</ColumnType>
<Length>0</Length>
<IsRequired>true</IsRequired>
</TableColumn>
<TableColumn>
<Name>Column3</Name>
<ColumnType>Number</ColumnType>
<Length>0</Length>
</TableColumn>
<TableColumn>
<Name>Column4</Name>
<ColumnType>Date</ColumnType>
<Length>0</Length>
<DefaultValue>2012-11-20</DefaultValue>
</TableColumn>
<TableColumn>
<Name>Column5</Name>
<ColumnType>DateTime</ColumnType>
<Length>0</Length>
<DefaultValue>2012-11-20 11:08:33.565</DefaultValue>
</TableColumn>
<TableColumn>
<Name>Column6</Name>
<ColumnType>Boolean</ColumnType>
<Length>0</Length>
<DefaultValue>False</DefaultValue>
</TableColumn>
<TableColumn>
<Name>Column7</Name>
<ColumnType>Double</ColumnType>
<Length>0</Length>
</TableColumn>
<TableColumn>
<Name>Column8</Name>
<ColumnType>SubscriberEmail</ColumnType>
<Length>0</Length>
</TableColumn>
</Columns>
</Details>
</ApiResponse>
|