fa
Feedback

فریب کلاهبرداران را نخورید! تل‌متریو این کانال‌ها را شناسایی و برچسب‌گذاری می‌کند 👉 برای مشاهده برچسب، اشتراک تهیه کنید

PostgreSQL DBA

PostgreSQL DBA

رفتن به کانال در Telegram

Sharing knowledge about postgresql database

نمایش بیشتر
2 036
مشترکین
اطلاعاتی وجود ندارد24 ساعت
اطلاعاتی وجود ندارد7 روز
+130 روز
آرشیو پست ها
Unused Indexes: Identify and remove unused indexes to reduce write overhead. The pg_stat_all_indexes view provides information about index usage.

Index Bloat: As data is inserted, updated, and deleted, indexes can become fragmented and bloated, leading to performance degradation. Rebuild indexes periodically using the REINDEX command.

Statistics: PostgreSQL relies on statistics to estimate the cost of different query plans. Inaccurate statistics can lead to suboptimal plan choices. Regularly update statistics using the ANALYZE command.

Partial indexes index only a subset of the table's rows, based on a condition. This can reduce index size and improve performance when queries frequently filter on that condition.

Composite indexes index multiple columns. The order of columns in a composite index is important. The most frequently used column in WHERE clauses should come first.

photo content

Indexes are crucial for improving query performance, but they also add overhead to write operations. Choosing the right indexes and maintaining them properly is essential.

Filtering: Where clauses that filter the data. If a filter is being applied after a large amount of data has already been processed, this is a sign the query could be optimized.

Rows: The estimated number of rows returned by each operation. Significant discrepancies between estimated and actual rows (observed with EXPLAIN ANALYZE) can indicate inaccurate statistics, leading the planner to choose a suboptimal plan.

Cost: The estimated cost of each operation. The planner uses a cost model to estimate the resources required to perform each operation. Higher costs usually indicate potential bottlenecks.

photo content

Bitmap Scans (Bitmap Index Scan, Bitmap Heap Scan): Used when multiple indexes might apply to a query. The database creates bitmaps representing rows matching each index condition and then combines these bitmaps before fetching the rows from the table. Can be useful when combining multiple filter conditions.

Index Scans (Index Scan, Index Only Scan): Using an index to locate rows. Index Scan requires fetching the actual row data from the table after using the index, while Index Only Scan can retrieve all necessary data directly from the index itself (highly efficient).

Sequential Scans (Seq Scan): Reading the entire table row by row. This is generally inefficient for large tables, especially when filtering on specific columns. Indicates a lack of suitable indexes or that the planner determined an index scan would be more expensive.

photo content

photo content

photo content

photo content

photo content

photo content

PostgreSQL DBA - آمار و تحلیل کانال تلگرام @postgres_tech