- INSERT INTO word (word_id, word_token, word, search_name_count)
- SELECT full_token, ' ' || lookup_term, norm_term, 0 FROM unnest(lookup_terms) as lookup_term;
+ INSERT INTO word (word_id, word_token, info)
+ SELECT full_token, lookup_term,
+ json_build_object('word', norm_term, 'count', 0)
+ FROM unnest(lookup_terms) as lookup_term;