The Driver Relationship team wants to have quick search options for the active drivers. The team specifically mentioned that they are using first name, last name and driving license ID to search the drivers. Create an index called NameSearch on the ACTIVE_DRIVERS table created in task 3. SQL Database TestIncomplete Create an INDEX to search the ACTIVE_DRIVERS table
SQL
SQL stands for Structured Query Language, is a form of communication that uses queries structured in a specific format to store, manage & retrieve data from a relational database.
Queries
A query is a type of computer programming language that is used to retrieve data from a database. Databases are useful in a variety of ways. They enable the retrieval of records or parts of records, as well as the performance of various calculations prior to displaying the results. A search query is one type of query that many people perform several times per day. A search query is executed every time you use a search engine to find something. When you press the Enter key, the keywords are sent to the search engine, where they are processed by an algorithm that retrieves related results from the search index. Your query's results are displayed on a search engine results page, or SER.
Task 4:
The Driver Relationship team wants to have quick search options for the active drivers. The team specifically mentioned that they are using first name, last name and driving license ID to search the drivers. Create an index called NameSearch on the ACTIVE_DRIVERS table created in task 3.
SQL
Create an INDEX to search the ACTIVE_DRIVERS table
Test Query
SHOW INDEX FROM ACTIVE_DRIVERS
Table | Non_unique | Key_name | Seq_in_index | Column_name | Collation | Cardinality | Sub_part | Packed | Null | Index_type | Comment | Index_comment | Visible | Expression |
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
ACTIVE_DRIVERS | 0 | PRIMARY | 1 | DRIVER_ID | A | 3 | NULL | NULL | BTREE | YES | NULL | |||
ACTIVE_DRIVERS | 1 | NameSearch | 1 | DRIVER_FIRST_NAME | A | 3 | NULL | NULL | YES | BTREE | YES | NULL | ||
ACTIVE_DRIVERS | 1 | NameSearch | 2 | DRIVER_LAST_NAME | A | 3 | NULL | NULL | YES | BTREE | YES | NULL | ||
ACTIVE_DRIVERS | 1 | NameSearch | 3 | DRIVER_DRIVING_LICENSE_ID | A | 3 | NULL | NULL | YES | BTREE | YES | NULL |

Step by step
Solved in 2 steps with 1 images









