Duplicate Rows Indicator¶
/api/repositories/{repository}/entities/{entity}/duplicatesindicator
Parameter | Type | Purpose |
---|---|---|
repository | string | the name of the Repository |
entity | int | The ID of the entity to view |
-
GET
/api/repositories/
(string: repository)/entities/
(int: entityID)/duplicatesindicator
¶ Lists the sets of duplicate rows in the Entity
GET /api/repositories/jupiter/entities/1/duplicatesindicator HTTP/1.1
Accept: application/json
Response Code | Reason |
---|---|
200 | No error |
500 | Server error |
The response will be a Standard Response, with a list of Value, Frequency and distribution of each row in the Entity.
The columns
array will contain the list of columns for each data row.
Human Name | Column Name | Description |
---|---|---|
Value | _col0 | The data value |
Frequency | _col1 | The number of times the value occurs in the entity |
Dist % | _col2 | A measure of how much of the data contains this value |
duplicate rows indicator will contain the details of the corresponding row of the Entity:
"rows": [
{
"dataRow": [
"1",
"2",
"25.000"
],
"metadata": {
"url": "/api/repositories/beta/entities/9/duplicatesindicator/1/duplicates"
}
}
]
If there are no duplicate rows in the Entity, rows
will be an empty string.
Commands¶
-
POST
/api/repositories/
(string: repository)/entities/{entity}/duplicatesindicator
¶ Executes commands for the duplicate rows indicator in the repositories.
The request requires a Standard Request packet. Available commands are:
Command | Description |
---|---|
get | Get a filtered list of duplicate rows indicator from an entity from the repository |
The response is a Standard Response; the datarows array will have an element for each row that matches the criteria.
Get¶
POST /api/repositories/jupiter/entities/1/duplicatesindicator HTTP/1.1
Content-Type: application/json
{
"command": "get"
}
Response Code | Reason |
---|---|
200 | Success |
500 | Server error |
The request packet must contain the command
and options
elements. The data
element is not required.
All fields are required.
Export¶
Some or all of the rows may be exported as a scheduled task.
POST /api/repositories/jupiter/entities/1/duplicatesindicator HTTP/1.1
Content-Type: application/json
{
"command": "export",
"data": {
"filename": "filename.csv",
"filetype": "csv",
"encoding": "utf-8"
},
"options": {
"columns": ["_value", "FREQUENCY_COUNT", "_distribution"],
"where": "'Frequency' >= 4"
}
}
Response Code | Reason |
---|---|
200 | No error |
400 | Invalid data passed with request |
500 | Server error |
The request packet must contain the command
and data
elements. The options
element is not required, but may specify the columns to export, and/or the rows to filter.
The following table shows which fields are required in the data
element:
Field | Required |
---|---|
filename | Y |
filetype | N |
encoding | N |
If filetype
is not specified, it defaults to csv. If encoding
is not specified, it defaults to the server native encoding.
The response will contain the URL of the scheduled task and the link to download the exported file.
{
"job": "/api/repositories/jupiter/scheduler/1",
"file": "/api/repositories/jupiter/download/filename.csv"
}