Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 3612102
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 18, 20262026-05-18T21:57:28+00:00 2026-05-18T21:57:28+00:00

Is postresql capable of doing a full text search, based on ‘half’ a word?

  • 0

Is postresql capable of doing a full text search, based on ‘half’ a word?
For example I’m trying to seach for "tree", but I tell postgres to search for "tr".

I can’t find such a solution that is capable of doing this.

Currently I’m using

 select * from test, to_tsquery('tree') as q where vectors @@ q ;

But I’d like to do something like this:

 select * from test, to_tsquery('tr%') as q where vectors @@ q ;
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-18T21:57:29+00:00Added an answer on May 18, 2026 at 9:57 pm

    Sounds like you simply want wildcard matching.

    • One option, as previously mentioned is trigrams. My (very) limited experience with it was that it was too slow on massive tables for my liking (some cases slower than a LIKE). As I said, my experience with trigrams is limited, so I might have just been using it wrong.

    • A second option you could use is the wildspeed module: http://www.sai.msu.su/~megera/wiki/wildspeed
      (you’ll have to build & install this tho).

    The 2nd option will work for suffix/middle matching as well. Which may or may not be more than you’re looking for.

    There are a couple of caveats (like size of the index), so read through that page thoroughly.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

PostgreSQL is about to make me punch small animals. I'm doing the following SQL
Can you do somwthing like this in postresql? select min(column1, column2) as Min, max(column1,
I have a reasonably sized postresql dump (around 270 mb) that I'm importing into
I am attempting to make an application capable of running on both Sql Server
I'm trying to use a function with PostgreSQL to save some data. Here is
I’m looking for a way to build web site which uses PostreSQL to store
Using PostgreSQL 8.4, I'm trying to put together the following query: SELECT (field_a +
I'm trying to group by month some rows using HQL, but I'm kind of
I have such postresql query: SELECT * , u.image AS image_name, k.id AS cat_id,
I am using postresql but i am realy bad at construting sql queries. I

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.