What is indexing in mysql and how do we create indexing in
mysql
Answer Posted / ramesh n
Indexes are created on a per column basis. If you have a
table with the columns: name, age, birthday and employeeID
and want to create an index to speed up how long it takes to
find employeeID values in your queries, then you would need
to create an index for employeeID. When you create this
index, MySQL will build a lookup index where employeeID
specific queries can be run quickly. However, the name, age
and birthday queries would not be any faster.
Indexes are something extra that you can enable on your
MySQL tables to increase performance,cbut they do have some
downsides. When you create a new index MySQL builds a
separate block of information that needs to be updated every
time there are changes made to the table. This means that if
you are constantly updating, inserting and removing entries
in your table this could have a negative impact on performance.
syntax
CREATE TABLE <table name> (
<filed name> <field type>....
)
| Is This Answer Correct ? | 2 Yes | 1 No |
Post New Answer View All Answers
What is the importance of "method" attribute in a html form?
Do you know what's the difference between __sleep and __wakeup?
Explain some of the php array functions?
List some features of php that are deprecated in php7?
What do you mean by having php as whitespace insensitive?
What is difference between readonly and constant?
How can i execute PHP File using Command Line?
Tell me how to find current date and time?
Why do we use hooks?
How do I update php?
How is it possible to set an infinite execution time for php script?
How does cookies work in php?
What is namespaces in PHP?
Tell me will a comparison of an integer 12 and a string "13" work in php?
What are the 5 types of data?