Skip to main content

3 Query the Summary of an Optimization

Description: Query the summary of an optimization by optimization ID (analysisId).

3.1. Interface URL

 Post http://${server-host}:${server-port}/api/v1/getAnalysisSummary  

3.2. Request Parameters

FieldTypeRequiredDescription
userKeyStringYActivation code
analysisIdStringYOptimization ID (analysisId) returned when creating optimization

Request Example

{  
"userKey": "CB698418-88B25371-67F15F01-XXXXXXXX",
"analysisId": "1730503067658043394"
}

3.3. Response

FieldTypeDescription
codeintStatus code
messageStringDescription
dataObjectData

Data structure of data

FieldTypeDescription
statusStringOptimization execution status
analysisIdStringOptimization ID
numberOfQueryintNumber of SQL statements
numberOfSyntaxErrorintNumber of syntax errors
numberOfRewriteintNumber of rewrite optimizations
numberOfRewrittenQueryintNumber of rewritten SQL statements
numberOfViolationsintNumber of violated rules
numberOfViolatedQueryintNumber of queries that violated rules
numberOfIndexintNumber of recommended indices
numberOfQueryIndexintNumber of queries using recommended indices
performanceImprovedoublePerformance improvement percentage
summaryMarkdownStringSummary markdown
analysisRuleInfoObjectAnalysis rule violation information
ruleNameStringRule name
stmtNameStrStringStatement name defined in rule
analysisIndexInfoArrayAnalysis recommended index DDL list
summaryStatementInfoObjectAnalysis statement information list
analysisStmtIdStringStatement ID (used to query analysis statement details)
stmtNameStringStatement name
stmtTextStringStatement SQL text
costBeforedoubleCost before optimization
costAfterdoubleCost after optimization
numberOfRewriteintNumber of statement rewrite optimizations
numberOfViolationsintNumber of rule violations in statement
numberOfSyntaxErrorintNumber of syntax errors in statement
numberOfIndexintNumber of indices recommended for statement
numberOfHitIndexintNumber of valid indices for statement
performancedoubleStatement performance improvement percentage
contributingIndicesStringNames of contributing indices

Response Example

{  
"resultCode": 200,
"resultMsg": "Success",
"resultBody": {
"status": "success1",
"basicSummary": {
"analysisSummaryId": "1730522775702663170",
...
}
...
}
}