text-prefix search in 9.4's JSONB - Mailing list pgsql-general

From Andreas Joseph Krogh
Subject text-prefix search in 9.4's JSONB
Date
Msg-id VisenaEmail.30.15c221b911eedc69.147101d7852@tc7-on
Whole thread Raw
Responses Re: text-prefix search in 9.4's JSONB  (Vik Fearing <vik.fearing@dalibo.com>)
List pgsql-general
Hi all.
 
I'm excited about 9.4's new JSONB and search-performance.
 
Is it possible to combine tsearch's prefix-search with the new JSONB-format?
 
Something like this (pseudo-code):
SELECT '{"subject": "visena"}'::jsonb @>  '{"subject": to_tsquery('simple', '(vise:*|office:*)')}';
 
and have the above query match documents where subject contains the prefixes "vise" and "office", which would match subject="visena" and subject="officenet"
 
Would be ultimate cool if this was possible!
 
Thanks.
 
--
Andreas Jospeh Krogh
CTO / Partner - Visena AS
Mobile: +47 909 56 963
Attachment

pgsql-general by date:

Previous
From: David G Johnston
Date:
Subject: Re: conditional IF statements in postgresql
Next
From: Albe Laurenz
Date:
Subject: Re: conditional IF statements in postgresql