Grand Canyon University: SYM 400
You notice when running queries that the database is returning results very slowly. Make sure
to address the following: Discuss likely causes for the slow returns. Propose solutions for
speeding up the process. Explain why implementing the index will speed up queries.
, • Poor query performance can be based on any number of the following: poorly designed
indexes, missing indexes, large data sets, or inefficient query design. Optimizing your
queries has much to do with improving the speed at which queries run. One good way of
optimizing your queries is to try to avoid, as much as possible, the use of JOIN
commands because this tie up the database and slows performance when there is a
multitude of rows in tables. Another keyway to improve query performance is through
the use of indexes. Indexes work by creating a structured reference to data to pull back
the required information. This cuts down on general searching inside large data sets, as
the index allows more efficiency in directing the query to the relevant data. Indexes are to
be carefully designed and applied on frequently queried columns. A well-structured index
can give significantly faster query execution with greater throughput of the database.
Discuss two indexing issues that can negatively affect databases. Provide specific examples in
your discussion.
• One of the general problems in database indexing involves creating either irrelevant or
redundant indexes, which tend to degrade database performance only. An irrelevant
index is one that, for all intents and purposes, is not used in any query, whereas a
redundant index only uses up valuable storage and adds unnecessary overhead inside the
database without providing any actual performance benefit whatsoever. They exist pretty
much as a burden, rather than an asset, because they contribute nothing to the
optimization of query execution. Lastly, duplicate indexes happen where multiple
segments of data should have easily been merged and end up having their indexes
created. One common, simple example is where there are separate indexes on both the
`first_name` and
`last_name` fields; this is highly inefficient if most queries search for a full name. Instead