Open
Description
Suppose you have this table
CREATE TABLE articles (id int, object_data JSONB);
If object_data has two fields (article & timeCreatedAsFromServer)
The following returns the error
ERROR: attribute "((object_data -> 'timeCreatedAsFromServer')::bigint)" is not found in table
CREATE INDEX article_rum_idx ON articles
USING rum (to_tsvector('English', object_data->>'article') rum_tsvector_addon_ops, ((object_data -> 'timeCreatedAsFromServer')::bigint))
WITH (attach = '((object_data -> ''timeCreatedAsFromServer'')::bigint)', to = 'to_tsvector(''English'', object_data->>''article'')')
If you omit the WITH clause, it works as below!
CREATE INDEX article_rum_idx ON articles
USING rum (to_tsvector('English', object_data->>'article') rum_tsvector_addon_ops, ((object_data -> 'timeCreatedAsFromServer')::bigint))