Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2000 Forums
 SQL Server Development (2000)
 Using Full Text Searches

Author  Topic 

scelamko
Constraint Violating Yak Guru

309 Posts

Posted - 2007-06-19 : 09:48:05
fulltext search

I am new to full text search I have started the full text service and run the following script

CREATE TABLE FTsearch(
ID INT IDENTITY(1,1) NOT NULL
, FILTERTYPE VARCHAR(10) NOT NULL
, FILENAME VARCHAR(250)
, DATA VARBINARY(MAX),
constraint PK_DOCUMENT_FT PRIMARY KEY CLUSTERED
(
ID
)
)

INSERT INTO FTsearch(FILTERTYPE, FILENAME, DATA)
SELECT '.doc' AS FileType, 'AmSRE.doc' AS FileName,
* FROM OPENROWSET(BULK N'N:\Database\FullText\AmSRE.doc', SINGLE_BLOB) AS Data

I have inserted 2000 txt and tiff images into the FTSearch table.

1. Now how do I run the search for a string in the table.
2. Is the primary key on the correct column or do I need to change to 'DATA' column.
3. Does VARBINARY datatype on the column 'DATA' correct datatype on the fulltext column.

Any suggestions and inputs would help.

Thanks

harsh_athalye
Master Smack Fu Yak Hacker

5581 Posts

Posted - 2007-06-19 : 09:52:36
Full-text search is not for searching binary data, it is for searching character data in a huge table by adding full-text index on the table (which resides outside your database).

Harsh Athalye
India.
"The IMPOSSIBLE is often UNTRIED"
Go to Top of Page

scelamko
Constraint Violating Yak Guru

309 Posts

Posted - 2007-06-19 : 10:05:27
Harsh,

Can you please elaborate 'on the table which resides outside your database'. I created the table in the a database called FULLTEXT. Is this not the right way to do it?

any inputs would help

Thanks
Go to Top of Page
   

- Advertisement -