thanks Marcus.
But my question is , assume that you have a table which has first name, last name and type_code which has 10 million rows. The user may enter only two char's for the first name text and 2 char's for the last name char.
The select query looks like this,
select first_name,last_name from table_name where first_name like 'first name%' and last_name like 'last name%'
These two fields are indexed. Is it good to create a covering index or normal index for this?.
Does indexing the type_code and adding that into the where clause will help my query optimized?. So Does the above query is fast or,
select first_name,last_name from table_name where first_name like 'first name%' and last_name like 'last name%' and type_code = 'IN'
is fast?.
What extra I can do to make this search to the maximum optimized.
Thank you very much. I really need something broder which I can include.
Thanks!.