Structural Database Query Fingerprinting for Consistent Workload Management

Resolve Bottlenecks,
Find Innovative Solutions
Generate Solutions

Solution Overview

Problem

Database queries in different database system implementations may be assigned different identifiers due to minor differences in constants, leading to inconsistent workload management and inefficient resource allocation.

Innovation Solution

Generate a unique and consistent fingerprint for database queries by identifying sub-portions such as expressions, predicates, projections, commands, operators, and attributes, assigning identifiers, and applying a fingerprint function to create a fixed-length identifier.

Engineering Contradictions & Design Principles

VSEngineering Contradiction Analysis

1Measurement precision

If database queries are assigned identifiers based on exact constant values, then query identification is precise, but queries with minor constant differences are treated as different queries leading to inconsistent workload management

Engineering Contradiction:
Improvequery identification precisionVSAvoidworkload management consistency
Core Design Contradiction:
Measurement precisionVSReliability

Solution Approach 1:

The query identifier is segmented into two parts: a fingerprint component derived from the query structure (SQL statement, tables, columns, operators) and a parameter component derived from constant values. This segmentation allows the system to identify queries with minor constant differences as the same query type for workload management purposes while still maintaining the ability to distinguish exact query variations when needed.

Inventive Principle:
Principle #1Segmentation

Solution Approach 2:

A fingerprint function acts as an intermediary between the raw query text and the identifier assignment. This fingerprint function extracts structural features of the query (SELECT, FROM, WHERE, JOIN, etc.) and generates a consistent fingerprint that serves as the basis for identifier assignment, filtering out minor constant variations that would otherwise create inconsistent identifiers.

Inventive Principle:
Principle #24Intermediary (Mediator)

2Loss of information

If database queries are assigned unique identifiers for each variation, then query tracking is accurate, but workload management becomes inefficient due to treating similar queries as different

Engineering Contradiction:
Improvequery variation tracking accuracyVSAvoidworkload management efficiency
Core Design Contradiction:
Loss of informationVSProductivity

Solution Approach 1:

The identifier system is segmented to capture only the structurally significant portions of queries. By focusing on query structure (operators, tables, columns) rather than exact constant values, the system reduces the number of unique identifiers needed while maintaining adequate tracking capability for workload management and performance analysis.

Inventive Principle:
Principle #1Segmentation

Solution Approach 2:

The system changes the parameters used for identification from exact constant values to structural fingerprints. This parameter transformation reduces sensitivity to minor query variations while preserving the ability to identify and manage workload patterns, thereby improving productivity without significant loss of tracking accuracy.

Inventive Principle:
Principle #35Parameter changes

3Manufacturing precision

If database queries use detailed identifiers including all constants, then query specificity is high, but resource allocation becomes inefficient due to redundant processing of similar queries

Engineering Contradiction:
Improvequery specification precisionVSAvoidresource allocation efficiency
Core Design Contradiction:
Manufacturing precisionVSLoss of energy

Solution Approach 1:

The query representation is segmented into structure (fingerprint) and parameters (constants). The fingerprint captures the essential query pattern for resource allocation decisions, while constants are treated separately. This allows the system to allocate resources based on query structure alone, avoiding redundant processing of similar queries with different constant values.

Inventive Principle:
Principle #1Segmentation

Solution Approach 2:

Instead of storing and processing complete query definitions including all constants for resource allocation, the system uses fingerprint copies that represent the structural essence of the query. This copying approach reduces processing overhead and memory usage while maintaining sufficient precision for effective resource allocation.

Inventive Principle:
Principle #26Copying

Data Source

PatentUS12380111B2Fingerprints for database queries
Publication Date: 2025.08.05 HEWLETT PACKARD ENTERPRISE DEV LP
  • US12380111B2 patent drawing
  • US12380111B2 patent drawing
  • US12380111B2 patent drawing

AI summary

In some examples, a system identifies sub-portions of a database query, assigns identifiers to the identified sub-portions, and adds the identifiers to a data structure. The system generates a fingerprint representing the database query based on applying a fingerprint function on the data structure including the identifiers.