List the tables, fields and keys from an app
List the tables, fields and keys from an app by using the GetTablesAndKeys method.
Information noteThe fields inside each table are returned. The derived fields are returned if any.
Example
The handle of the app is 1.
1. List the tables and key fields.
The client sends:
{
"jsonrpc": "2.0",
"id": 1,
"method": "GetTablesAndKeys",
"handle": 1,
"params": [
{
"qcx": 1000,
"qcy": 1000
},
{
"qcx": 0,
"qcy": 0
},
30,
true,
false
]
}
The engine returns:
{
"jsonrpc": "2.0",
"id": 1,
"result": {
"qtr": [
{
"qName": "TempUnits",
"qNoOfRows": 2,
"qFields": [
{
"qName": "English/Metric",
"qOriginalFields": [],
"qPresent": true,
"qInformationDensity": 1,
"qnNonNulls": 2,
"qnRows": 2,
"qSubsetRatio": 1,
"qnTotalDistinctValues": 2,
"qnPresentDistinctValues": 2,
"qKeyType": "NOT_KEY",
"qTags": [
"$text"
],
"qDerivedFields": []
},
{
"qName": "TempUnit",
"qOriginalFields": [],
"qPresent": true,
"qInformationDensity": 1,
"qnNonNulls": 2,
"qnRows": 2,
"qSubsetRatio": 1,
"qnTotalDistinctValues": 2,
"qnPresentDistinctValues": 2,
"qKeyType": "NOT_KEY",
"qTags": [
"$ascii",
"$text"
],
"qDerivedFields": []
},
{
"qName": "PrecipUnit",
"qOriginalFields": [],
"qPresent": true,
"qInformationDensity": 1,
"qnNonNulls": 2,
"qnRows": 2,
"qSubsetRatio": 1,
"qnTotalDistinctValues": 2,
"qnPresentDistinctValues": 2,
"qKeyType": "NOT_KEY",
"qTags": [
"$ascii",
"$text"
],
"qDerivedFields": []
}
],
"qPos": {
"qx": 919,
"qy": 359
}
},
{
"qName": "GolfCourse Details",
"qNoOfRows": 47753,
"qFields": [
{
"qName": "GolfCourseKey",
"qOriginalFields": [],
"qPresent": true,
"qHasDuplicates": true,
"qInformationDensity": 1,
"qnNonNulls": 47753,
"qnRows": 47753,
"qSubsetRatio": 1,
"qnTotalDistinctValues": 17888,
"qnPresentDistinctValues": 17888,
"qKeyType": "ANY_KEY",
"qTags": [
"$key",
"$text"
],
"qDerivedFields": []
},
{
"qName": "Par",
"qOriginalFields": [],
"qPresent": true,
"qHasNull": true,
"qHasDuplicates": true,
"qInformationDensity": 0.99486943228697677,
"qnNonNulls": 47508,
"qnRows": 47753,
"qSubsetRatio": 1,
"qnTotalDistinctValues": 67,
"qnPresentDistinctValues": 67,
"qKeyType": "ANY_KEY",
"qTags": [
"$key",
"$numeric",
"$integer"
],
"qDerivedFields": []
},
{
"qName": "Slope",
"qOriginalFields": [],
"qPresent": true,
"qHasNull": true,
"qHasDuplicates": true,
"qInformationDensity": 0.9934244968902477,
"qnNonNulls": 47439,
"qnRows": 47753,
"qSubsetRatio": 1,
"qnTotalDistinctValues": 122,
"qnPresentDistinctValues": 122,
"qKeyType": "ANY_KEY",
"qTags": [
"$key",
"$numeric",
"$integer"
],
"qDerivedFields": []
},
{
"qName": "Rating",
"qOriginalFields": [],
"qPresent": true,
"qHasNull": true,
"qHasDuplicates": true,
"qInformationDensity": 0.9934244968902477,
"qnNonNulls": 47439,
"qnRows": 47753,
"qSubsetRatio": 1,
"qnTotalDistinctValues": 420,
"qnPresentDistinctValues": 420,
"qKeyType": "ANY_KEY",
"qTags": [
"$key"
],
"qDerivedFields": []
}
],
"qPos": {
"qx": 147,
"qy": 497
}
}
],
"qk": [
{
"qKeyFields": [
"GolfCourseKey"
],
"qTables": [
"GolfCourse",
"GolfCourse Details",
"GolfCourseMeasurements"
]
},
{
"qKeyFields": [
"Par"
],
"qTables": [
"GolfCourse Details",
"AvgParRangeMatch"
]
},
{
"qKeyFields": [
"Rating"
],
"qTables": [
"GolfCourse Details",
"AvgRaitingRangeMatch"
]
},
{
"qKeyFields": [
"Slope"
],
"qTables": [
"GolfCourse Details",
"AvgSlopeRangeMatch"
]
},
{
"qKeyFields": [
"AirportCode"
],
"qTables": [
"GolfCourse",
"MonthlyWeather"
]
},
{
"qKeyFields": [
"Avg_Green_Fee"
],
"qTables": [
"GolfCourseMeasurements",
"AvgGreenFeeRangeMatch"
]
},
{
"qKeyFields": [
"Avg_Temp_F"
],
"qTables": [
"MonthlyWeather",
"AvgTempRangeMatch_F"
]
},
{
"qKeyFields": [
"Avg_Temp_C"
],
"qTables": [
"MonthlyWeather",
"AvgTempRangeMatch_C"
]
}
]
}
}
The list of tables, fields and keys is returned. The list of derived fields is empty.