full-text-search

Why does Full Text Search get this result?

A Full-Text query like this one: SELECT * FROM TABLE1 WHERE CONTAINS(COL1,'"x* ray*"') gets all rows containing any combination of x and ray but not one without the other. If we modified the query this way SELECT * FROM TABLE1 WHERE CONTAINS(COL1,'"x* ray* "') --With a space after ray* it gets all rows not only containing any combi...

Sphinx delta indexing -- still necessary to rebuild the main index?

I've been reading up on the Sphinx search engine and the Thinking Sphinx gem. In the TS docs it says... Sphinx has one major limitation when compared to a lot of other search services: you cannot update the fields [of] a single document in an index, but have to re-process all the data for that index. If I understand correctly, that...

Implementing proximity operators in full-text search

Some databases (e.g. Scopus and Web of Science) implement proximity operators such as SAME or NEAR. With these the user can define that he wants his search words to be within a set number of words from each other or in the same sentence or paragraph. I just started wondering how this is implemented. Full-text search as is is not that co...

How do I increase Relevance value in an advanced MySQL query?

I've got a MySQL query similar to the following: SELECT *, MATCH (`Description`) AGAINST ('+ipod +touch ' IN BOOLEAN MODE) * 8 + MATCH(`Description`) AGAINST ('ipod touch' IN BOOLEAN MODE) AS Relevance FROM products WHERE ( MATCH (`Description`) AGAINST ('+ipod +touch' IN BOOLEAN MODE) OR MATCH(`LongDescription`) AGAINST ('+ipod +touch'...

Pattern (regex) based searching systems

I'm looking for a way to search through terabytes of data for patterns matching regexes. The implementation does need to support a lot of the finer capabilities of regexes, such as beginning and end of line data, full TR1 support (preferably with POSIX and/or PCRE support), and the like. We're effectively using this application to test...

What is the meaning of O( polylog(n) )? In particular, how is polylog(n) defined?

Brief: When academic (computer science) papers say "O(polylog(n))", what do they mean? I'm not confused by the "Big-Oh" notation, which I'm very familiar with, but rather by the function polylog(n). They're not talking about the complex analysis function Lis(Z) I think. Or are they? Something totally different maybe? More detail: Mos...

SQL Server Fulltext - multiple columns

Hi All, I have what I think is a very basic scenario, but what I've read makes it sound like this is not easy in SQL Server Fulltext. I have 2 columns, First and Last name. I want to support fulltext search on them such that if someone types "John Smith" people with a match on both first and last come up first. Problem is, although i...

Full-text index population performance on a SQL 2005 indexed view

I have created an indexed view: CREATE VIEW LogValueTexts WITH SCHEMABINDING AS SELECT ISNULL(LRVS_SLOG_ID*256+LRVS_IDX,0) AS ID,LRVS_VALUE AS Value FROM dbo.LRVS_LogRecordedValues WHERE LEN(LRVS_VALUE)>4 CREATE UNIQUE CLUSTERED INDEX IX_LogValueTexts ON LogValueTexts (ID) On SQL 2005 Standard SP3 it takes forever to populate a full-...

How do you concatenate strings inside of a CONTAINS in SQL Server 2008?

SQL Server 2008 is telling me that it doesn't like the "+" in the CONTAINS. Not sure what I'm doing wrong here. INSERT INTO dbo.tblImportTitles ( ImportTitleGUID, UserGUID, TitleName, TitleGUID ) SELECT ImportTitleGUID = T.Item.value('@ImportTitleGUID', 'uniqueidentifier'), UserGUID = T.Item.value('@UserGUID', 'u...

SQL Server FullText Search (Windows Service) - Failure

Hi all, I've been asked to look at a server issue but for some reason I am unable to track down the cause. Basically, they have SQL Server 2005 (Workgroup Ed) that has a number of databases running. One of which has Full Text indexing enabled on a table. When trying to read the data regardless of what client I use, I get Timeout ...

SOLR - delta import not with last_modified

I saw only ways using delta import with last_modified. Is there some other ways to do delta_imports withut using timestamps? For example, if i have unique key(integer), can i tell SOLR to index only those, which are greater then my last unique key? ...

SQL Server 2008 CTE And CONTAINSTABLE Statement - Why the error?

I am testing out moving our database from SQL Server 2005 to 2008. We use CTE's for paging. When using full-text CONTAINSTABLE, the CTE will not run and generates an error. Here's my non-working code- WITH results AS ( SELECT ROW_NUMBER() over (ORDER BY GBU.CreateDate DESC ) as rowNum, GBU.UserID, NULL AS DistanceInMi...

SQL Server: How to order by date, if the date is < GetDate()

Hi, Here's an interesting one... hope I can explain it well... I have a collection of competitions in a single table in my SQL Server DB. I'm doing a full text search over them, which works fine. However, some of the competitions are closed, and I want these closed comps to show up after the open comps, while still respecting the rank ...

Full-text search across concatenated columns?

I'm new to free-text search, so pardon the newbie question. Suppose I have the following full-text index: Create FullText Index on Contacts( FirstName, LastName, Organization ) Key Index PK_Contacts_ContactID Go I want to do a freetext search against all three columns concatenated FirstName + ' ' + LastName + ' ' + Organi...

SQL FTS no results from Containstable query

Quick FTS question. I have a table(Person) with 10 varchar columns (fname, surname, hair colour, etc), I've create a FT Index on it however queries using containstable return nothing for 'AND' queries e.g. FROM CONTAINSTABLE(tablename, *, 'john AND doe', 20) or CONTAINSTABLE(tablename, *, '(FORMSOF(INFLECTIONAL, john) AND FORMSOF(INFLE...

Find and replace multiple strings in file then output to new filename python

I am looking to create a python script that will read one source file then produce another file with a string for the name. for example macaddress.cnf.xml contains the source file I need to change '6000' to '6001' in multiple places of macaddress.cnf.xml, then I want to output to newmacaddress.cnf.xl. This is what I have #! /usr/...

Can MySQL fulltext search be adapted to search for partial words?

I implemented MySQL fulltext search and worked perfect. Now the client wants that partial matches be found by the search, for example the term 'base' should match 'database'. I know the whole idea of fulltext search is based on word delimiters, and searching for full words. I know I most likely will have to use an undesirable LIKE '%$ter...

SQL Server 2008 extremely slow using FTS on joined tables

I have two tables Product (id int, brandid int,Name nvarchar(1000)) 2+ million rows Brand (id int,name nvarchar(1000)) 20k rows FullText index is enabled on both table's name field. If I do a search such as SELECT count(*) FROM Product p join Brand b on p.BrandID = b.ID WHERE contains(b.name,'calvin') Runs super fast...

Full text search on a bound DataGridView control

Hello all, I cannot seem to be able to find a way to do a full text search on a databound DataGridView control across the entire breath of its columns and rows. The DataTable and DataView objects seems to force me into searching for specific columns either through Select(), Find(), or FindRows(). Same with the DataGridView control. I ...

Hibernate Search question

I am using Hibernate Search and applied Lucene indexing on one table for a domain object. I want now to make selection from this table for domain objects and apply filtering based on joining with other table, which is not indexed. For exampple, I have Auction Lots table, which I have indexed. And I have Quotes table. Quotes have referen...