Tagged articles
205 articles
Page 2 of 3
Liangxu Linux
Liangxu Linux
Aug 22, 2022 · Databases

Why MySQL Unique Indexes Fail with NULL and How to Fix Them

This article explains why a MySQL UNIQUE index does not prevent duplicate rows when indexed columns contain NULL, explores the complications of logical‑delete tables, and presents practical solutions such as incrementing delete status, adding timestamps, delete‑id keys, hash fields, and proper batch inserts.

Database designIndex OptimizationLogical Delete
0 likes · 15 min read
Why MySQL Unique Indexes Fail with NULL and How to Fix Them
Efficient Ops
Efficient Ops
Jul 20, 2022 · Databases

How Indexes Can Speed Up MySQL Queries by Tens of Thousands of Times

This article walks through a MySQL scenario where a nested sub‑query runs for hours, demonstrates how adding single‑column and multi‑column indexes, rewriting the query as a join, and analyzing execution plans can reduce execution time from thousands of seconds to a few milliseconds.

Database TuningIndex OptimizationSQL
0 likes · 12 min read
How Indexes Can Speed Up MySQL Queries by Tens of Thousands of Times
ITPUB
ITPUB
Jul 15, 2022 · Backend Development

How I Cut a 20‑Second API Call to Sub‑Second with Three Simple Optimizations

A backend engineer shares a step‑by‑step case study of reducing a batch‑score query API from 20 seconds to under 500 ms by analyzing the problem, adding a composite index, introducing multithreaded CompletableFuture calls, and limiting batch size with pagination and thread‑pool tuning.

API performanceBackendIndex Optimization
0 likes · 11 min read
How I Cut a 20‑Second API Call to Sub‑Second with Three Simple Optimizations
dbaplus Community
dbaplus Community
Jul 11, 2022 · Databases

Why Is MySQL Query Slow? Hidden Factors Beyond Indexes and How to Fix Them

This article explains why MySQL queries can become sluggish, covering the full query execution flow, profiling techniques, index pitfalls, connection‑pool limits, buffer‑pool sizing, and additional performance tricks, while providing concrete commands and code examples for each optimization step.

Connection PoolIndex OptimizationProfiling
0 likes · 16 min read
Why Is MySQL Query Slow? Hidden Factors Beyond Indexes and How to Fix Them
Liangxu Linux
Liangxu Linux
Jul 9, 2022 · Databases

How Indexes Transform MySQL Subquery Performance: A Deep Dive

This article walks through a MySQL 5.6 scenario where a subquery that originally took over eight hours is accelerated by orders of magnitude through strategic index creation, query rewriting, and join optimization, illustrating the impact of single‑column, composite, and covering indexes on execution plans.

Index OptimizationJOINSubquery
0 likes · 13 min read
How Indexes Transform MySQL Subquery Performance: A Deep Dive
MaGe Linux Operations
MaGe Linux Operations
Jun 28, 2022 · Databases

How Indexes Can Speed Up MySQL Queries by 50,000×: A Deep Dive

This article walks through a MySQL scenario with large tables, demonstrates why a sub‑query that took over eight hours runs in just a second after adding appropriate single‑column and composite indexes, and explains how to read and interpret execution plans for further tuning.

Index OptimizationSQLdatabase
0 likes · 11 min read
How Indexes Can Speed Up MySQL Queries by 50,000×: A Deep Dive
ITPUB
ITPUB
Jun 14, 2022 · Databases

12 Common MySQL Slow‑Query Causes and How to Fix Them

This article enumerates twelve typical reasons why MySQL queries become slow—such as missing or ineffective indexes, deep pagination, massive tables, excessive joins, large IN lists, dirty pages, file‑based ORDER BY, and hardware limits—and provides concrete SQL examples and step‑by‑step optimization techniques to resolve each issue.

Database PerformanceIndex Optimizationmysql
0 likes · 33 min read
12 Common MySQL Slow‑Query Causes and How to Fix Them
Su San Talks Tech
Su San Talks Tech
Jun 6, 2022 · Databases

Why Is MySQL Query Slow? Hidden Factors Beyond Indexes and How to Fix Them

This article explores the various reasons MySQL queries become slow—including index misuse, insufficient connection pools, small InnoDB buffer pools, and query cache limitations—while providing practical solutions such as optimizing indexes, adjusting max_connections, enlarging buffer pools, and configuring connection pools for better performance.

Connection PoolIndex OptimizationInnoDB
0 likes · 16 min read
Why Is MySQL Query Slow? Hidden Factors Beyond Indexes and How to Fix Them
Ops Development Stories
Ops Development Stories
Jun 5, 2022 · Databases

What Really Happens Inside MySQL When You Run a SELECT Query?

This article walks through the complete lifecycle of a MySQL SELECT statement, from establishing the TCP connection and authentication, through query cache, parsing, optimization, and execution, detailing how the server and storage engine collaborate and explaining concepts like index usage, connection handling, and memory management.

Database ArchitectureIndex OptimizationQuery Execution
0 likes · 20 min read
What Really Happens Inside MySQL When You Run a SELECT Query?
Java Backend Technology
Java Backend Technology
Apr 28, 2022 · Databases

Why MySQL Pagination Slows Down at High Offsets and How to Fix It

This article recounts a production incident caused by a MySQL query with a huge OFFSET, explains why large offsets lead to full‑table scans and severe latency, and presents three practical solutions—including index‑covering subqueries, start‑position redefinition, and offset throttling—along with data‑generation scripts and performance test results.

Index OptimizationSQLmysql
0 likes · 14 min read
Why MySQL Pagination Slows Down at High Offsets and How to Fix It
Big Data Technology & Architecture
Big Data Technology & Architecture
Apr 13, 2022 · Databases

Common MySQL Index Failure Scenarios and Optimization Techniques

This article explains typical MySQL index failure cases such as left‑most matching truncation, implicit conversion, IN + ORDER BY, range queries, leading wildcard, OR conditions, function usage, NOT IN/!=, low selectivity, and index fragmentation, and provides practical optimization strategies including index redesign, covering indexes, and pagination improvements.

Database PerformanceIndex OptimizationQuery Tuning
0 likes · 17 min read
Common MySQL Index Failure Scenarios and Optimization Techniques
Youzan Coder
Youzan Coder
Feb 17, 2022 · Databases

Master MySQL Slow Query Optimization: Practical Indexing Techniques

This article shares hands‑on experience with MySQL 5.7 slow‑query problems, explaining common causes, proper index design, pitfalls that invalidate indexes, efficient SQL writing, deep‑pagination avoidance, and how to use EXPLAIN to verify that queries leverage the right indexes.

Database PerformanceExplain PlanIndex Optimization
0 likes · 16 min read
Master MySQL Slow Query Optimization: Practical Indexing Techniques
dbaplus Community
dbaplus Community
Feb 6, 2022 · Databases

10 Common MySQL Index Pitfalls and How to Avoid Them

This article walks through ten typical scenarios where MySQL indexes fail—covering left‑most prefix violations, SELECT *, calculations, functions, type mismatches, LIKE patterns, column comparisons, OR, NOT IN/NOT EXISTS, and ORDER BY—showing why each occurs and how to keep indexes effective.

Index OptimizationSQLcovering index
0 likes · 22 min read
10 Common MySQL Index Pitfalls and How to Avoid Them
NiuNiu MaTe
NiuNiu MaTe
Dec 15, 2021 · Databases

Master MySQL Performance: Practical Tuning, Indexes, and Scaling Strategies

This comprehensive guide walks through MySQL performance fundamentals, real‑world testing results, slow‑query detection, index impact, pagination pitfalls, count optimizations, sharding techniques, and step‑by‑step migration plans for large tables, equipping engineers with actionable tuning insights.

Index Optimizationdatabase scalingmysql
0 likes · 13 min read
Master MySQL Performance: Practical Tuning, Indexes, and Scaling Strategies
360 Quality & Efficiency
360 Quality & Efficiency
Dec 3, 2021 · Databases

Understanding MySQL Slow Query Analysis with EXPLAIN

This article explains why SQL queries become slow in MySQL, describes the server architecture, details how to use the EXPLAIN statement to interpret execution plans, and outlines how to read and optimize key fields such as type, key, and extra for better performance.

Database PerformanceIndex Optimizationexplain
0 likes · 5 min read
Understanding MySQL Slow Query Analysis with EXPLAIN
Ops Development Stories
Ops Development Stories
Nov 9, 2021 · Databases

Master MySQL Index Optimization: 10 Practical Tips to Avoid Index Pitfalls

This article demonstrates how to create and use a sample employees table, explains composite index structures, and provides ten concrete MySQL index best‑practice guidelines—covering full‑value matches, leftmost‑prefix rules, avoiding functions, range conditions, covering indexes, inequality, NULL checks, leading wildcards, type conversions, and OR usage—each illustrated with EXPLAIN output and code examples.

Database PerformanceIndex OptimizationSQL
0 likes · 10 min read
Master MySQL Index Optimization: 10 Practical Tips to Avoid Index Pitfalls
Wukong Talks Architecture
Wukong Talks Architecture
Oct 25, 2021 · Databases

MySQL Index Optimization and Code Review Practices

This article explains MySQL index fundamentals, the B+Tree structure, various index types, the concept of covering indexes to avoid row look‑ups, the left‑most prefix rule, and presents three real‑world optimization cases that illustrate how to design effective composite indexes, reduce index size, and improve query performance while avoiding costly table scans and sorts.

Code reviewComposite IndexDatabase Performance
0 likes · 13 min read
MySQL Index Optimization and Code Review Practices
Code Ape Tech Column
Code Ape Tech Column
Sep 26, 2021 · Databases

MySQL Index Optimization: Fundamentals, Types, and Practical Cases

This article explains MySQL index fundamentals, B+‑tree implementation, the left‑most prefix rule, back‑to‑table issues, and provides three practical optimization cases with code examples to help developers design efficient composite indexes and avoid performance pitfalls.

Index OptimizationSQLdatabase
0 likes · 15 min read
MySQL Index Optimization: Fundamentals, Types, and Practical Cases
Top Architect
Top Architect
Aug 18, 2021 · Big Data

Elasticsearch Indexing and Retrieval Optimization for Billion‑Scale Data

This article describes how a top architect optimized Elasticsearch for handling billions of records, covering Lucene fundamentals, index and shard design, DocValues, query performance tuning, bulk indexing strategies, hardware considerations, and testing methods to achieve sub‑second query responses across multi‑year data ranges.

Big DataElasticsearchIndex Optimization
0 likes · 12 min read
Elasticsearch Indexing and Retrieval Optimization for Billion‑Scale Data
Big Data Technology & Architecture
Big Data Technology & Architecture
Aug 7, 2021 · Big Data

Elasticsearch Optimization Practices and Performance Tuning Guide

This article presents a comprehensive guide on optimizing Elasticsearch for large‑scale data platforms, covering Lucene fundamentals, index and shard architecture, doc‑values usage, routing strategies, practical performance‑tuning techniques, and real‑world testing results to achieve sub‑second query responses on billions of records.

ElasticsearchIndex Optimizationlucene
0 likes · 12 min read
Elasticsearch Optimization Practices and Performance Tuning Guide
Alibaba Cloud Developer
Alibaba Cloud Developer
Jul 30, 2021 · Databases

How to Tackle MySQL Slow Queries: Metrics, Strategies, and Real Cases

This article explains what constitutes a MySQL slow query, why they cause failures, defines quantitative metrics such as micro‑average and macro‑average to assess severity, outlines target goals, presents concrete optimization examples, and shares operational practices for ongoing slow‑SQL governance.

Database PerformanceIndex OptimizationMetrics
0 likes · 13 min read
How to Tackle MySQL Slow Queries: Metrics, Strategies, and Real Cases
Su San Talks Tech
Su San Talks Tech
Jul 21, 2021 · Databases

Why Index Hits Still Cause Slow Queries and How to Optimize MySQL

This article explains why a query that uses an index can still be slow, demonstrates how to diagnose index usage and row scans with EXPLAIN and the slow query log, and presents optimization techniques such as composite indexes, index condition pushdown, and virtual columns.

Index Optimizationexplainindex condition pushdown
0 likes · 10 min read
Why Index Hits Still Cause Slow Queries and How to Optimize MySQL
Laravel Tech Community
Laravel Tech Community
Jun 28, 2021 · Databases

Understanding and Optimizing MySQL ORDER BY Execution

This article explains how MySQL processes ORDER BY clauses, illustrates the execution steps with a full‑field index, discusses the impact of sort_buffer and max_length_for_sort_data, and shows how adding composite and covering indexes can eliminate filesort and improve query performance.

Index OptimizationOrder BySQL Performance
0 likes · 6 min read
Understanding and Optimizing MySQL ORDER BY Execution
Code Ape Tech Column
Code Ape Tech Column
May 21, 2021 · Databases

Why Your MySQL Queries Are Slow and How ElasticSearch & HBase Can Help

This article analyzes common causes of slow MySQL queries such as index misuse, MDL locks, and large‑table bottlenecks, then presents practical solutions like proper indexing, sharding, read/write splitting, and evaluates when to complement MySQL with ElasticSearch or HBase for better performance.

Database PerformanceElasticsearchHBase
0 likes · 19 min read
Why Your MySQL Queries Are Slow and How ElasticSearch & HBase Can Help
Code Ape Tech Column
Code Ape Tech Column
May 8, 2021 · Databases

Understanding MySQL Pagination Performance and Index Optimization

The article explores why MySQL pagination with large offsets is slow, explains index structures such as clustered and secondary indexes, describes logical query operators, and presents two practical optimization strategies to improve query performance.

Database PerformanceIndex OptimizationQuery Planning
0 likes · 6 min read
Understanding MySQL Pagination Performance and Index Optimization
JavaEdge
JavaEdge
Apr 13, 2021 · Databases

How MySQL Executes ORDER BY: Full-Field vs RowID Sorting and Index Optimization

This article explains MySQL's ORDER BY execution process, comparing full-field sorting with rowid sorting, detailing how sort_buffer, temporary files, and index usage affect performance, and showing how composite and covering indexes can eliminate sorting altogether.

Composite IndexIndex OptimizationOrder By
0 likes · 13 min read
How MySQL Executes ORDER BY: Full-Field vs RowID Sorting and Index Optimization
Programmer DD
Programmer DD
Apr 6, 2021 · Databases

Why MySQL Pagination Is So Slow and How to Fix It

This article explores why MySQL queries with large LIMIT‑OFFSET pagination become painfully slow, explains the underlying B+‑tree index mechanics and MySQL's logical operator layers, and presents two practical solutions—key‑based pagination and index‑covering queries—to dramatically improve performance.

B+TreeDatabase PerformanceIndex Optimization
0 likes · 7 min read
Why MySQL Pagination Is So Slow and How to Fix It
Code Ape Tech Column
Code Ape Tech Column
Mar 15, 2021 · Databases

Why Large OFFSETs Slow MySQL Queries and How to Fix Them

A developer discovers that massive OFFSET values in MySQL pagination cause full‑table scans and severe latency, then reproduces the issue with simulated data, benchmarks the slowdown, and presents three practical solutions—including index‑covering subqueries, cursor‑based pagination, and offset limits—to restore query performance.

Index OptimizationKeyset PaginationLarge OFFSET
0 likes · 16 min read
Why Large OFFSETs Slow MySQL Queries and How to Fix Them
Top Architect
Top Architect
Mar 5, 2021 · Big Data

Elasticsearch Indexing and Search Optimization: Principles, Lucene Internals, and Performance Tuning

This article explains the architecture and core concepts of Elasticsearch and Lucene, outlines the requirements for cross‑month and high‑speed queries on massive datasets, and provides detailed index and search performance tuning techniques—including bulk writes, shard routing, doc‑values management, and pagination strategies—to achieve sub‑second response times on billions of records.

Big DataElasticsearchIndex Optimization
0 likes · 13 min read
Elasticsearch Indexing and Search Optimization: Principles, Lucene Internals, and Performance Tuning
Code Ape Tech Column
Code Ape Tech Column
Jan 20, 2021 · Databases

Why Does MySQL Pick the Wrong Index? A Deep Dive into Query Optimization

This article examines a slow MySQL query that scans millions of rows, explains why the optimizer chose a low‑selectivity index, demonstrates how forcing the correct index dramatically improves performance, and shows how to create a covering composite index to resolve the issue permanently.

Database TuningExplain PlanIndex Optimization
0 likes · 8 min read
Why Does MySQL Pick the Wrong Index? A Deep Dive into Query Optimization
Java Interview Crash Guide
Java Interview Crash Guide
Jan 12, 2021 · Databases

Boost MySQL Query Speed: Index Tricks, Join vs Subquery, and Execution Plan Hacks

This article walks through a MySQL 5.6 case study where a nested sub‑query for finding students scoring 100 in a specific subject runs for hours, then demonstrates how adding single‑column and composite indexes, rewriting the query as a join, and analyzing execution plans can shrink the runtime from tens of thousands of seconds to under a second.

Database TuningIndex OptimizationQuery Planning
0 likes · 11 min read
Boost MySQL Query Speed: Index Tricks, Join vs Subquery, and Execution Plan Hacks
ITPUB
ITPUB
Sep 30, 2020 · Databases

Mastering MySQL Index Usage: When and How Queries Leverage Indexes

This guide explains the conditions under which MySQL can use indexes for range scans, LIKE patterns, BETWEEN clauses, and sorting, detailing key_len calculation, index key vs. filter vs. table filter, and practical examples to demystify index utilization.

Database PerformanceIndex OptimizationQuery Planning
0 likes · 10 min read
Mastering MySQL Index Usage: When and How Queries Leverage Indexes
Code Ape Tech Column
Code Ape Tech Column
Sep 20, 2020 · Databases

20 Principles for MySQL Index Optimization

This article presents twenty practical rules for optimizing MySQL indexes—including when to use or avoid indexes, how to write queries that can leverage them, the importance of index selectivity, prefix indexes, covering indexes, and common pitfalls—to help developers write faster, more efficient SQL statements.

Database PerformanceIndex OptimizationQuery Tuning
0 likes · 16 min read
20 Principles for MySQL Index Optimization
Code Ape Tech Column
Code Ape Tech Column
Aug 29, 2020 · Databases

20 Essential MySQL Index Optimization Rules Every Developer Should Know

This article outlines twenty practical principles for optimizing MySQL indexes, covering topics such as LIKE wildcards, UNION/IN/OR usage, negative conditions, composite index prefix rules, range queries, function avoidance, covering indexes, prefix indexes, pagination strategies, and common misconceptions, all illustrated with SQL examples and performance tips.

Database PerformanceIndex OptimizationQuery Tuning
0 likes · 16 min read
20 Essential MySQL Index Optimization Rules Every Developer Should Know
Suning Technology
Suning Technology
Jul 30, 2020 · Databases

Why Auto‑Increment IDs, Redundant Fields, and Index Limits Matter in Database Design

This article explores key database design decisions—including the benefits and drawbacks of auto‑increment primary keys, the trade‑offs of redundant columns, optimal index counts, and when to choose VARCHAR versus CHAR—offering practical guidelines to improve performance, storage efficiency, and maintainability.

Database designIndex Optimizationauto-increment primary key
0 likes · 11 min read
Why Auto‑Increment IDs, Redundant Fields, and Index Limits Matter in Database Design
21CTO
21CTO
Jul 9, 2020 · Databases

How to Optimize Large MySQL Tables: Index Tuning, Online DDL, and Efficient Deletion

This article walks through diagnosing severe SLA alerts caused by slow queries on a massive MySQL table, analyzes query patterns with pt‑query‑digest, redesigns indexes, applies online DDL and pt‑osc for index changes, and demonstrates batch‑delete techniques that dramatically reduce execution time and replication lag.

Batch DeleteIndex OptimizationLarge Tables
0 likes · 15 min read
How to Optimize Large MySQL Tables: Index Tuning, Online DDL, and Efficient Deletion
Efficient Ops
Efficient Ops
Jul 1, 2020 · Databases

Essential MySQL Naming, Design, and Indexing Standards for Reliable Databases

This guide outlines comprehensive MySQL best practices covering naming conventions, table engine and charset choices, field type selection, index design principles, common index column recommendations, ordering of composite indexes, avoidance of redundant and foreign‑key constraints, SQL development rules, and operational guidelines for large‑scale data handling.

Database designIndex OptimizationSQL Best Practices
0 likes · 21 min read
Essential MySQL Naming, Design, and Indexing Standards for Reliable Databases
Ctrip Technology
Ctrip Technology
Jun 29, 2020 · Backend Development

Optimizing Ctrip’s Vacation Search Engine: From Search 1.0 to 5.5

This article details the evolution and optimization of Ctrip’s vacation search engine, covering business challenges, indexing redesign, data collection pipelines, write‑path improvements, compression techniques, query performance enhancements, deployment strategies, and the resulting gains in storage, latency, and stability.

BackendIndex OptimizationScalability
0 likes · 14 min read
Optimizing Ctrip’s Vacation Search Engine: From Search 1.0 to 5.5
Java Captain
Java Captain
Jun 21, 2020 · Databases

Why Using SELECT * Is Inefficient in MySQL and How Indexes Improve Performance

Although many developers hear the advice to avoid using SELECT * in SQL, this article delves into the underlying reasons—such as increased parsing cost, unnecessary data transfer, extra I/O, and loss of covering-index optimization—while also explaining index concepts and best practices for MySQL performance.

Database PerformanceIndex OptimizationSQL
0 likes · 10 min read
Why Using SELECT * Is Inefficient in MySQL and How Indexes Improve Performance
macrozheng
macrozheng
Jun 8, 2020 · Databases

Why MySQL’s Index Choice Can Miss the Best Plan – A Deep Cost Analysis

This article examines how MySQL estimates execution costs for queries, explains why COUNT(*) can be optimal, demonstrates index selection with real‑world examples, and shows how optimizer_trace can reveal mismatches between estimated and actual performance.

Index OptimizationOptimizer_traceSQL Performance
0 likes · 10 min read
Why MySQL’s Index Choice Can Miss the Best Plan – A Deep Cost Analysis
Top Architect
Top Architect
Jun 7, 2020 · Databases

MySQL Performance Optimization: Data Volume, Concurrency, Index Design, and SQL Tuning

This article presents a comprehensive guide to MySQL performance improvement, covering maximum data volume, connection limits, query latency targets, practical implementation principles, optimal table design, index classification and tuning, as well as detailed SQL optimizations such as batch processing, operator rewriting, and pagination techniques.

Index OptimizationSQL Tuningmysql
0 likes · 16 min read
MySQL Performance Optimization: Data Volume, Concurrency, Index Design, and SQL Tuning
Laravel Tech Community
Laravel Tech Community
May 18, 2020 · Databases

MySQL Large‑Table Index Optimization and Delete Performance Improvement

This article analyzes a MySQL master‑slave instance with a massive arrival_record table, identifies slow‑query causes using pt‑query‑digest and tcpdump, proposes index redesign, demonstrates backup/restore with mydumper, compares online DDL and pt‑osc, and presents batch‑delete strategies that dramatically reduce SLA‑triggering latency.

BackupBatch DeleteIndex Optimization
0 likes · 14 min read
MySQL Large‑Table Index Optimization and Delete Performance Improvement
Youzan Coder
Youzan Coder
Apr 29, 2020 · Databases

MySQL Slow Query Analysis: Root Causes and Optimization Strategies

The article examines why MySQL queries become slow, detailing system‑level issues such as network latency, I/O bottlenecks, and CPU settings, alongside database‑level problems like missing indexes, type conversion, poor execution plans, lock contention, skewed data, and inefficient SQL patterns, and offers optimization strategies.

Database PerformanceIndex OptimizationInnoDB
0 likes · 15 min read
MySQL Slow Query Analysis: Root Causes and Optimization Strategies
Java Backend Technology
Java Backend Technology
Apr 20, 2020 · Databases

Why Indexes Can Still Cause Slow Queries and How to Optimize Them

This article explains why using indexes does not guarantee fast queries, explores the relationship between index usage and slow‑query logs, and presents practical MySQL optimization techniques such as improving index selectivity, reducing table‑lookup costs, and leveraging virtual columns.

Index Optimizationmysqlslow-query
0 likes · 14 min read
Why Indexes Can Still Cause Slow Queries and How to Optimize Them
Aikesheng Open Source Community
Aikesheng Open Source Community
Mar 17, 2020 · Databases

Understanding MySQL Index Optimization and Execution Flow

This article explains MySQL index design principles, demonstrates the execution steps of a range query on a sample table, and discusses common index optimizations such as covering indexes, the left‑most prefix rule, index condition push‑down, implicit type conversion, as well as why the optimizer may choose a wrong index and how to correct it.

Database PerformanceIndex OptimizationQuery Execution
0 likes · 9 min read
Understanding MySQL Index Optimization and Execution Flow
Efficient Ops
Efficient Ops
Feb 9, 2020 · Databases

Why a MySQL Query Took 30 Seconds and How a Hidden Index Cut It to 0.2 s

A production MySQL query on a table with five million rows took over 30 seconds, and after reproducing the issue, examining execution plans, trying various index and query tweaks, discovering that SQLyog adds a hidden LIMIT, and finally forcing the correct index, the runtime dropped to under a second, illustrating the importance of proper index usage and tool‑specific quirks.

Index OptimizationSQLyogexecution plan
0 likes · 6 min read
Why a MySQL Query Took 30 Seconds and How a Hidden Index Cut It to 0.2 s
Java Captain
Java Captain
Jan 26, 2020 · Databases

MySQL Slow Query Optimization: Reducing Execution Time from 30 Seconds to 0.19 Seconds

This article documents a MySQL slow‑query case where a 5‑million‑row table took over 30 seconds to run a GROUP BY query, explores several ineffective optimization attempts, reveals a client‑side limit issue, and finally solves the problem by forcing the correct index, cutting the runtime to under 0.2 seconds.

Index Optimizationdistinct vs group byexecution plan
0 likes · 5 min read
MySQL Slow Query Optimization: Reducing Execution Time from 30 Seconds to 0.19 Seconds
Aikesheng Open Source Community
Aikesheng Open Source Community
Dec 11, 2019 · Databases

MySQL CPU Saturation Case Study: Analyzing and Optimizing a Slow ORDER BY Query

This article examines a MySQL instance that hit 100% CPU at 9 am on 2019‑01‑11, identifies the offending ORDER BY query through slow‑log and EXPLAIN analysis, and demonstrates how adding a composite index and correcting implicit type conversions reduced execution time from over 10 seconds to milliseconds.

Index Optimizationmysqlperformance tuning
0 likes · 7 min read
MySQL CPU Saturation Case Study: Analyzing and Optimizing a Slow ORDER BY Query
dbaplus Community
dbaplus Community
Dec 10, 2019 · Backend Development

How to Optimize Elasticsearch for Billions of Records: Practical Tuning Guide

An in‑depth guide walks through Elasticsearch’s underlying Lucene architecture, explains shard routing and DocValues, then presents concrete index‑ and search‑performance tweaks—bulk writes, refresh intervals, memory allocation, SSD usage, field mapping, pagination strategies—and shows benchmark results that reduce query latency to seconds for billions of records.

Big DataElasticsearchIndex Optimization
0 likes · 13 min read
How to Optimize Elasticsearch for Billions of Records: Practical Tuning Guide
Architecture Digest
Architecture Digest
Nov 22, 2019 · Big Data

Elasticsearch Optimization Practices for Large‑Scale Data Platforms

This article presents a comprehensive guide to optimizing Elasticsearch for massive data volumes, covering Lucene fundamentals, index and shard design, practical performance‑tuning techniques, and real‑world testing results that enable cross‑month queries and sub‑second response times.

Big DataElasticsearchIndex Optimization
0 likes · 14 min read
Elasticsearch Optimization Practices for Large‑Scale Data Platforms
NetEase Game Operations Platform
NetEase Game Operations Platform
Aug 24, 2019 · Databases

MongoDB Index Optimization for High‑Write CMDB Workloads and Slow‑Log Reduction

This article analyzes the performance bottlenecks of a MongoDB‑based CMDB under high write concurrency, explains index structures and storage, demonstrates how to identify and eliminate full‑table scans and redundant multikey indexes, and shows the resulting reduction in slow‑log volume and CPU usage.

Index OptimizationMongoDBdatabase
0 likes · 36 min read
MongoDB Index Optimization for High‑Write CMDB Workloads and Slow‑Log Reduction
FunTester
FunTester
Jul 31, 2019 · Databases

Why MySQL Join Query Slowed to 30,000 Seconds and How Restoring an Index Fixed It

The author describes a sudden 30,000‑second slowdown in a simple MySQL join query, details systematic diagnostics—including network, server load, and query testing—and ultimately discovers a missing index on the user_info table, restoring it to bring response times back to sub‑second levels.

Index OptimizationSQL Joindatabase troubleshooting
0 likes · 4 min read
Why MySQL Join Query Slowed to 30,000 Seconds and How Restoring an Index Fixed It
Java Backend Technology
Java Backend Technology
Jul 23, 2019 · Databases

Why Alibaba Bans Joins Over Three Tables: Real‑World MySQL & Oracle Benchmarks

This article investigates Alibaba's rule against joining more than three tables by designing MySQL and Oracle experiments that generate massive student‑teacher‑course data, run multi‑table join queries, compare indexed versus non‑indexed scenarios, and reveal the performance limits that drive the guideline.

Data GenerationDatabase PerformanceIndex Optimization
0 likes · 12 min read
Why Alibaba Bans Joins Over Three Tables: Real‑World MySQL & Oracle Benchmarks
ITPUB
ITPUB
Jul 8, 2019 · Databases

How to Supercharge MySQL Queries with Index Optimization: A Step‑by‑Step Guide

This article walks through a real‑world MySQL scenario, showing how a slow sub‑query can be accelerated by adding single‑column indexes, converting the query to a join, and finally creating a composite index, with performance numbers and execution‑plan analysis to illustrate each optimization step.

Database TuningIndex OptimizationSQL Performance
0 likes · 11 min read
How to Supercharge MySQL Queries with Index Optimization: A Step‑by‑Step Guide
Programmer DD
Programmer DD
Jul 2, 2019 · Databases

Why MySQL LIMIT Slows Down on Large Offsets and How to Fix It

This article analyzes why MySQL LIMIT pagination becomes increasingly slow with larger offsets, presents six optimization techniques—including using primary keys, covering indexes, prepared statements, subqueries, and composite indexes—and provides experimental results that demonstrate dramatic performance improvements.

Index OptimizationSQLmysql
0 likes · 12 min read
Why MySQL LIMIT Slows Down on Large Offsets and How to Fix It
ITPUB
ITPUB
Jun 18, 2019 · Databases

Why MySQL LIMIT Pagination Slows Down and 6 Proven Optimization Techniques

This article examines why MySQL LIMIT pagination becomes slower as the offset grows, presents six practical methods—including direct LIMIT, primary‑key indexing, ordered index scans, prepared statements, sub‑queries, and joins—provides benchmark results on large tables, and distills actionable guidelines for designing covering and composite indexes to achieve fast, stable pagination.

Index OptimizationLIMITSQL
0 likes · 12 min read
Why MySQL LIMIT Pagination Slows Down and 6 Proven Optimization Techniques
Java Captain
Java Captain
Mar 29, 2019 · Databases

MySQL Query Optimization: Indexing Strategies and Execution Plan Analysis

This article demonstrates how to dramatically improve MySQL query performance by analyzing execution plans, adding appropriate single‑column and composite indexes, converting subqueries to EXISTS or JOINs, and leveraging index coverage and ordering, with detailed examples and timing results.

Index OptimizationSQL Tuningexecution plan
0 likes · 12 min read
MySQL Query Optimization: Indexing Strategies and Execution Plan Analysis
21CTO
21CTO
Jan 19, 2019 · Databases

Essential MySQL Standards: Naming, Design, Indexing, and SQL Best Practices

This guide outlines comprehensive MySQL standards covering object naming conventions, basic design rules, field type choices, index creation strategies, and SQL development practices to improve performance, maintainability, and security across database projects.

Index OptimizationSQL Standardsmysql
0 likes · 18 min read
Essential MySQL Standards: Naming, Design, Indexing, and SQL Best Practices
Java Captain
Java Captain
Dec 22, 2018 · Databases

MySQL Database Design, Slow Query Issues, and Handling Mistakes

This article discusses MySQL table design choices, partitioning methods, index best practices, common causes of slow queries with optimization tips, useful diagnostic tools, and recommended actions when accidental operations or bugs affect data.

Data RecoveryIndex OptimizationSlow Queries
0 likes · 10 min read
MySQL Database Design, Slow Query Issues, and Handling Mistakes
WeChat Client Technology Team
WeChat Client Technology Team
Dec 6, 2018 · Databases

How SQLiteLint Detects Hidden Performance Issues in Mobile Apps

This article introduces SQLiteLint, a runtime analysis tool that automatically checks SQLite usage in mobile apps for index problems, redundant indexes, SELECT *, AUTOINCREMENT, missing prepared statements, and without‑rowid opportunities, enabling developers to catch performance issues before release.

Index OptimizationMobile DevelopmentSQLite
0 likes · 17 min read
How SQLiteLint Detects Hidden Performance Issues in Mobile Apps
Efficient Ops
Efficient Ops
Nov 28, 2018 · Databases

Master MySQL Indexes: When and How They’re Used for Queries

This article explains how MySQL decides whether an index can be used for range queries, LIKE patterns, and sorting, detailing key_len calculation, index key vs. filter vs. table filter concepts, and practical examples with BETWEEN and ORDER BY.

Database PerformanceIndex OptimizationQuery Planning
0 likes · 11 min read
Master MySQL Indexes: When and How They’re Used for Queries
Youzan Coder
Youzan Coder
Sep 14, 2018 · Big Data

Elasticsearch Optimization and Index Splitting Strategies in the Youzan Search System

The Youzan search system uses middleware‑driven Elasticsearch optimizations—segment merging, larger buffers, routing, and rollover—to cut index files and document scans, splits large indices into business‑specific or hot‑cold sub‑indices, and adds asynchronous cross‑datacenter replication with soft‑delete versioning for high‑availability and scalable performance.

ElasticsearchHot/Cold IsolationIndex Optimization
0 likes · 10 min read
Elasticsearch Optimization and Index Splitting Strategies in the Youzan Search System
Beike Product & Technology
Beike Product & Technology
Jun 1, 2018 · Databases

InnoDB Transaction and Index Principles

This article explains InnoDB's transaction and index principles, covering ACID properties, transaction logs, MVCC, locking mechanisms, and B+ tree index structures to help backend developers understand how InnoDB ensures data consistency and high concurrency.

ACIDB+TreeIndex Optimization
0 likes · 11 min read
InnoDB Transaction and Index Principles
Java Captain
Java Captain
May 19, 2018 · Databases

MySQL Index Optimization and Performance Analysis

This article explains MySQL index fundamentals, demonstrates performance issues with slow queries, and walks through practical optimization cases using EXPLAIN, covering index creation, covering indexes, and composite indexes, and best practices for when to add or avoid indexes.

Index OptimizationSQL Performancedatabase
0 likes · 17 min read
MySQL Index Optimization and Performance Analysis
dbaplus Community
dbaplus Community
May 9, 2018 · Databases

How We Migrated MySQL from Docker Swarm to Alibaba RDS and Fixed a CPU Crisis

This article recounts a real‑world MySQL migration from Docker Swarm containers to an Alibaba Cloud RDS instance, detailing the original architecture, migration steps, backup scripts, a critical index‑missing outage, and the practical indexing strategies used to restore performance.

Backup ScriptDocker SwarmIndex Optimization
0 likes · 13 min read
How We Migrated MySQL from Docker Swarm to Alibaba RDS and Fixed a CPU Crisis
Java Backend Technology
Java Backend Technology
Apr 8, 2018 · Databases

Master MySQL: Table Design, Slow Query Fixes, and Recovery Strategies

This article reviews common MySQL pitfalls—including engine choice, table partitioning, index design, slow‑query causes and optimizations, diagnostic tools, and how to recover from accidental data loss—offering practical guidance for developers to improve performance and reliability.

Database designIndex OptimizationPartitioning
0 likes · 10 min read
Master MySQL: Table Design, Slow Query Fixes, and Recovery Strategies
Qunar Tech Salon
Qunar Tech Salon
Dec 20, 2017 · Databases

Diagnosing and Resolving MySQL InnoDB Deadlocks and Lock‑Wait Timeouts in Data‑Warehouse Workloads

This article explains how to quickly locate and fix online MySQL problems such as partial update failures, InnoDB deadlocks, and lock‑wait timeouts by analyzing server logs, understanding InnoDB row‑lock behavior, optimizing indexes, adjusting transaction settings, and using a custom log‑collection script.

Database PerformanceIndex OptimizationInnoDB
0 likes · 19 min read
Diagnosing and Resolving MySQL InnoDB Deadlocks and Lock‑Wait Timeouts in Data‑Warehouse Workloads
ITPUB
ITPUB
Nov 25, 2017 · Databases

How to Handle Billions of Rows in SQL Server: Bulk Insert, Partitioning, and Index Tuning

This article walks through a real‑world monitoring project that must store over 400 million rows per day in SQL Server 2012, detailing the performance bottlenecks, bulk‑copy tuning, schema redesign, partitioning strategies, index removal and creation, and query‑optimisation techniques that finally achieve sub‑second query times and meet strict latency requirements.

Bulk InsertIndex OptimizationPartitioning
0 likes · 16 min read
How to Handle Billions of Rows in SQL Server: Bulk Insert, Partitioning, and Index Tuning
21CTO
21CTO
Nov 18, 2017 · Databases

Boost MySQL Performance: Config Tweaks, Index Strategies, and Essential Tools

This article walks through practical MySQL optimization techniques—including configuration file tuning, key InnoDB parameters, effective index design, and the use of Percona and MySQL Tuner tools—to help you speed up queries and eliminate performance bottlenecks in production environments.

ConfigurationIndex Optimizationmysql
0 likes · 17 min read
Boost MySQL Performance: Config Tweaks, Index Strategies, and Essential Tools
ITPUB
ITPUB
Oct 25, 2017 · Databases

Mastering MySQL ORDER BY: Principles, Optimizations, and Index Pitfalls

This article explains how MySQL processes ORDER BY, compares conventional, optimized, and priority‑queue sorting algorithms, shows how to leverage indexes, and provides practical tuning tips such as adjusting max_length_for_sort_data and sort_buffer_size to avoid costly temporary files and random I/O.

Index OptimizationOrder BySorting Algorithms
0 likes · 12 min read
Mastering MySQL ORDER BY: Principles, Optimizations, and Index Pitfalls
Programmer DD
Programmer DD
Sep 19, 2017 · Databases

Why MySQL Ignored My Index and How to Speed Up Periodic Deletions

The article investigates why a seemingly indexed MySQL DELETE query still performs a full‑table scan, analyzes execution plans and statistics, demonstrates forcing the index, and finally rewrites the query to limit the date range, achieving a much faster operation.

Database PerformanceIndex OptimizationSQL
0 likes · 7 min read
Why MySQL Ignored My Index and How to Speed Up Periodic Deletions
360 Zhihui Cloud Developer
360 Zhihui Cloud Developer
Aug 22, 2017 · Databases

Mastering MongoDB Connection, Authentication, and Query Optimization

This article explains common MongoDB connection problems, authentication mechanisms, read‑preference tuning, index types and creation, query‑plan analysis, pagination techniques, and array handling, offering practical tips to improve performance and reliability for developers.

AuthenticationConnection ManagementIndex Optimization
0 likes · 9 min read
Mastering MongoDB Connection, Authentication, and Query Optimization
Qunar Tech Salon
Qunar Tech Salon
May 24, 2017 · Databases

Common Scenarios Where SQL Fails to Use Indexes and How to Resolve Them

This article explains eight typical situations in which Oracle SQL statements cannot use indexes, illustrates each case with concrete examples and step‑by‑step rewrites, and offers practical solutions—including predicate adjustments, function indexes, and query‑transformation fixes—to improve database performance.

Database PerformanceIndex OptimizationOracle
0 likes · 12 min read
Common Scenarios Where SQL Fails to Use Indexes and How to Resolve Them
dbaplus Community
dbaplus Community
May 22, 2017 · Databases

Why Your SQL Queries Skip Indexes and How to Make Them Use Indexes

This article explains eight common reasons why Oracle SQL statements fail to use indexes, provides concrete rewrite techniques, shows how optimizer bugs can block index usage, and outlines practical steps for enforcing SQL development standards through automated audit tools.

Database PerformanceIndex OptimizationOracle
0 likes · 13 min read
Why Your SQL Queries Skip Indexes and How to Make Them Use Indexes
转转QA
转转QA
May 9, 2017 · Databases

MySQL Slow Query and Index Optimization

This article explains how to identify and analyze MySQL slow queries using tools like SHOW VARIABLES, EXPLAIN, mysqldumpslow, and profiling, and provides practical recommendations for configuring server variables, optimizing indexes, and improving query performance through systematic testing and best‑practice SQL design.

Index OptimizationSQLmysql
0 likes · 18 min read
MySQL Slow Query and Index Optimization
ITPUB
ITPUB
Feb 19, 2017 · Databases

Turning an 89ms Query into 0ms: Real‑World SQL Server Index Optimization

The article recounts a performance bottleneck in a Windows service that processed only about 12 records per second, analyzes why a simple SELECT TOP 1 query without proper indexes caused 89 ms latency, and demonstrates step‑by‑step how adding appropriate clustered and non‑clustered indexes reduced the execution time to virtually zero, while also discussing broader indexing strategies and common LEFT JOIN pitfalls.

Clustered IndexDatabase TuningIndex Optimization
0 likes · 9 min read
Turning an 89ms Query into 0ms: Real‑World SQL Server Index Optimization
ITPUB
ITPUB
Jun 21, 2016 · Databases

Eliminate Bookmark Lookups in SQL Server: Index Strategies Explained

This article explains what bookmark (key) lookups are in SQL Server, shows how they appear in execution plans, and presents three practical indexing techniques—clustered indexes, covering indexes with INCLUDE, and index intersection—to remove the extra I/O overhead.

Bookmark LookupInclude ClauseIndex Intersection
0 likes · 6 min read
Eliminate Bookmark Lookups in SQL Server: Index Strategies Explained
dbaplus Community
dbaplus Community
Jun 7, 2016 · Databases

Master MySQL Data Types and Index Optimization for Faster Queries

This guide explains how to choose optimal MySQL data types, use enums, handle dates, and design efficient indexes—including B‑tree, prefix, and covering indexes—while also covering storage engine differences, maintenance commands, and normalization strategies to boost database performance.

Data TypesDatabase PerformanceIndex Optimization
0 likes · 16 min read
Master MySQL Data Types and Index Optimization for Faster Queries
dbaplus Community
dbaplus Community
Feb 2, 2016 · Databases

Unlock SQL Speed: Real-World Optimization Tricks and Techniques

This article walks through practical Oracle SQL optimization methods—explaining execution plans, indexes, statistics, hints, and partitioning—using concrete examples and step‑by‑step case studies that show how to dramatically reduce query runtimes and CPU load.

Index OptimizationOracleSQL
0 likes · 24 min read
Unlock SQL Speed: Real-World Optimization Tricks and Techniques