Minimum Row Length Matches

/api/repositories/{repository}/entities/{entity}/rows/minlength/matches
Parameter Type Purpose
repository string the name of the Repository
entity int The ID of the entity to view

Get

GET /api/repositories/(string: repository)/entities/(int: entityID)/rows/minlength/matches

Lists the shortest row(s) in the Entity

GET /api/repositories/jupiter/entities/1/rows/minlength/matches HTTP/1.1
Accept: application/json
Response Code Reason
200 No error
500 Server error

The response will be a Standard Response, showing the shortest rows the Entity.

The columns array will contain the list of columns for each data row. The first 4 column will be:

Human Name Column Name Description
Row :rowid: The row number
Row Length _original_row_length The row length
Checksum _hex_checksum The checksum of the row (Identifies candidate duplicate rows)
Row Value Count _value_count The number of non-null values in the row

Each attribute in the entity will have an element in the array.

The rows array data row will contain the rows from the Entity; the metadata will contain the URL to drill-down to row details:

{
    "rows": [
        {
            "dataRow": [
                "51",
                "41401",
                "/06/1",
                "989H6",
                "7541001007",
                "01/06/",
                "198",
                "9 \ ",
                "\ \ ",
                ""
            ],
            "metadata": {
                "url": "/api/repositories/alpha/entities/36/rows/minlength/matches/51/details"
            }
        }
    ]
}

If there are no rows in the Entity, rows will be an empty string.

Post

POST /api/repositories/(string: repository)/entities/(int: entityID)/rows/minlength/matches

Lists the shortest row(s) in the Entity, allow user to pass in supported options (Paging, Columns & Cache) see Standard Request for more information on these options.

POST /api/repositories/jupiter/entities/1/rows/minlength/matches HTTP/1.1
Content-Type: application/json

{
    "command": "get",
    "options": {
        "pageStart": "1",
        "pageSize": "65",
        "columns": ["Line_01"]
    }
}
Response Code Reason
200 Success
400 Bad Request
500 Server error

The request packet must contain the command element. The options elements is optional.

The response will be a Standard Response, showing the shortest rows in the Entity.

The columns array will contain the list of columns for each data row, similar to the ‘GET’ request, unless they are filtered using the ‘columns’ option.

NOTE: Please note that this view is cached on the server, hence if columns were filtered previously, you must reset the view to return all columns again by forcing the view to flush the cache as shown:

POST /api/repositories/jupiter/entities/1/rows/minlength/matches HTTP/1.1
Content-Type: application/json

{
    "command": "get",
    "options": {
       "cache": "flush"
    }
}

Export

Some or all of the rows may be exported as a scheduled task.

POST /api/repositories/jupiter/entities/1/rows/minlength/matches HTTP/1.1
Content-Type: application/json

{
    "command": "export",
    "data": {
        "filename": "filename.csv",
        "filetype": "csv",
        "encoding": "utf-8"
    },
    "options": {
        "where": "Row = 21"
    }
}
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"
}