I have one table with 4 columns. One is primary key and other three columns are references to columns of other tables. I am using join on these four tables for a search filter. These joins are taking time.
So I was thinking to have indexes on columns because I read that I should create indexes on columns of join conditions. My question is will there be problem if all columns of the table are indexed? Is there any other way to decrease time complexity of these search filters.
- Table1(main search)-1000 million entries primary_key fk1 fk2 fk3
- Table2-800 million entries pk1 ..(8-9 columns)
- Table3-700 million entries pk2 ..(10-12 columns)
- Table2-850 million entries pk3 ..(7-8 columns)
I am using MyISAM engine.