Fix datastore index creation.

Use bind parameters for to_tsvector() parameters instead of format
strings.

Handling of building the full text search indexes has been seperated out
from index creation