MySQL中对于经纬度字段如何添加索引提高性能

现在有一个客户表,location字段用于记录客户的经纬度坐标,例如:
create table customer(
id int primary key auto_increment,
location GEOMETRY,
name varchar(256)
)
为了查询性能优化,需要给location字段加上 索引,该如何添加?


alter table customer
    modify location  GEOMETRY not null;
alter table customer
    add INDEX geo_index(location);