| From: | Kimball <kbighorse(at)gmail(dot)com> |
|---|---|
| To: | pgsql-general(at)postgresql(dot)org |
| Subject: | tsearch2 keep throw-away characters |
| Date: | 2007-05-16 01:14:13 |
| Message-ID: | a050b8390705151814i4c1c14daw7251f021b66d8cb6@mail.gmail.com |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-general |
postgres=# select to_tsvector('default','I know how to code in C#, java and
C++');
to_tsvector
-------------------------------------
'c':7,10 'code':5 'java':8 'know':2
(1 row)
postgres=# select to_tsvector('simple','I know how to code in C#, java and
C++');
to_tsvector
-------------------------------------------------------------------------
'c':7,10 'i':1 'in':6 'to':4 'and':9 'how':3 'code':5 'java':8 'know':2
(1 row)
I'd like to get lexemes/tokens 'c#' and 'c++' out of this query. Everything
I can find has to do with stop words. How do I keep characters that
tsearch throws out? I've already tried 'c\#' and 'c\\#' etc, which don't
work.
Kimball
| From | Date | Subject | |
|---|---|---|---|
| Next Message | camb | 2007-05-16 04:09:15 | Are foreign key's automatically set as indicies? |
| Previous Message | Justin Pasher | 2007-05-15 23:26:32 | Fixing broken permissions for deleted user |