Data Sync - Get Table Indexes

URI

https://164.99.19.131:8443/SentinelRESTServices/datasync/tableindexes

Supported Methods

GET

This returns the indexes for a table.

Authentication

Authentication Types
Sentinel Permissions Needed

Supported Formats

Response

URL Parameters

Required

ParameterTypeDescription
password String The password of the user.
schemaName String This is the name of the table whose indexes are being returned.
tableName String This is the name of the schema the table belongs to.

Optional

ParameterTypeDefault ValueDescription
hostName String localhost Name or IP address of database system where the table resides whose indexes are to be returned. If this parameter is missing, the default value will be "localhost".
port int 5432 Port for communicating with the database system where the table resides whose indexes are to be returned. If this parameter is missing, the default value will be "5432".
database String SIEM The name of the database in the database system where the table resides whose indexes are to be returned. If this parameter is missing, the default value will be "SIEM".
userName String appuser Name of the database user to login to the database system. If this parameter is missing, the default value will be "appuser".
dbPlatform String postgresql This is the platform of the database system. It may be <strong>postgresql</strong>, <strong>oracle11g</strong> or <strong>mssql2008</strong>. If this parameter is missing, the default value will be "postgresql".

Success Codes

Fault Codes

Response Data

Object type: Database table indexes
Information about the indexes for a given table
FieldDescription
indexesThis is a nested JSON object that returns the indexes for the table. Note that it contains a single internal field <B>index</B> that is an array of <B>&lt;Table Index&gt;</B> objects. See below for description of fields in Table Index objects.
schemaNameThis is the name of the schema the table belongs to.
tableNameThis is the name of the table whose indexes are being returned.

Response Data

Object type: Database table indexes
Further detail on the index fields
FieldDescription
indexColumnsThis is a nested JSON object that contains the index columns for the index. Note that it contains a single internal field <B>indexColumn</B> that is an array of objects. See below for description of fields in Index Column objects.
indexNameName of an index for the table.
uniqueFlag (true or false) indicating whether the index is a unique index.

Response Data

Object type: Database table fields
Information about the indexed columned for a given table
FieldDescription
columnNameName of table column that is to be indexed.
sortSequenceValue indicating whether the column values are sorted in ascending or descending order. A value of "A" indicates ascending order, and a value of "D" indicates descending order. This may be omitted if neither ascending or descending is applicable.

Sample Request

GET /datasync/tableindexes?hostName=164.99.19.125&port=5432&userName=appuser&password=star1111&dbPlatform=postgresql&schemaName=my_schema&#10;&tableName=my_table_name?hostName=164.99.19.125&port=5432&userName=appuser&password=star1111&dbPlatform=postgresql
Sample Response for application/json
Status: 200
{&#10;   "tableName": "my_table_name",&#10;   "schemaName": "my_schema",&#10;   "indexes": {"index":[{&lt;Table Index&gt;},{&lt;Table Index&gt;}...]}&#10;}&#10;&#10;Table Index Fields&#10;{&#10;   "indexName": "evt_id_index",&#10;   "indexColumns": {"indexColumn":[{&lt;Index Column&gt;},{&lt;Index Column&gt;}...]},&#10;   "unique": "true"&#10;&#10;}&#10;Index Column Fields&#10;{&#10;   "columnName": "evt_id",&#10;   "sortSequence": "A"&#10;}&#10;