I'm trying to create spatial index over table column (bbox polygon default NULL
) but get error: All parts of a SPATIAL index must be NOT NULL
.
Problem is that I supposed some rows would contain NULLs. The question is: is there a way to declare column with default empty polygon?
EMPTY
does not work in MySQL. dev.mysql.com/doc/refman/5.1/en/… – Bertieid
andpolygon
). Move the single field to an other table. Records without polygons can have no corresponding records in the other table, so a JOIN will return with null, but you will able to use spacial index the secondary table. – Bertie