Q1
True / FalseIn PostgreSQL, indexes are used to speed up the retrieval of rows from a table.
Indexes improve the performance of data retrieval operations by providing a faster way to locate rows in a table.
Q2
True / FalseIn PostgreSQL, creating an index automatically ensures that the data in the table is unique.
Creating a standard index does not enforce uniqueness; a unique index or primary key constraint is required to ensure unique values.
Q3
True / FalseIn PostgreSQL, indexes can be created on one or more columns of a table.
Indexes can be created on single or multiple columns, which can be beneficial for optimizing various types of queries.
Q4
True / FalseIn PostgreSQL, a B-tree index is the default type of index.
PostgreSQL uses B-tree indexes by default, which are suitable for a wide range of queries.
Q5
True / FalseIn PostgreSQL, creating too many indexes can slow down data modification operations.
While indexes speed up retrieval, they can slow down INSERT, UPDATE, and DELETE operations because the indexes must be updated with the data.
Q6
True / FalseIn PostgreSQL, the ANALYZE command updates the statistics of indexes as well as tables.
The ANALYZE command updates the statistics for both tables and their associated indexes, helping the query planner make informed decisions.
Q7
True / FalseIn PostgreSQL, partial indexes are indexes that only cover a subset of the rows in a table.
Partial indexes are created with a WHERE clause, indexing only the rows that meet the specified condition, which can be more efficient.
Q8
True / FalseIn PostgreSQL, GiST indexes are suitable for full-text search.
GiST indexes are used for geometric data types and other complex types. GIN indexes are typically used for full-text search in PostgreSQL.
Q9
True / FalseIn PostgreSQL, expression indexes can be used to index the result of a function or expression.
Expression indexes allow indexing of the result of a function or expression applied to one or more columns, which can optimize specific types of queries.
Q10
True / FalseIn PostgreSQL, using the REINDEX command can help fix corrupted indexes and improve database performance.
The REINDEX command rebuilds indexes, which can help fix corruption and improve performance by optimizing the index structure.