2011-10-07 9 views
7

Tôi không thể tìm kiếm toàn văn bản để làm việc trên các tệp PDF mà tôi tải vào tệp SQL Db thông qua FileStream.Tìm kiếm toàn văn bản SQL Server PDF không hoạt động trên FileStream PDF File

Version: SQL Server 2008 R2 (Developer Edition - làm bằng chứng của khái niệm) Hệ điều hành: Windows 7

bước tôi đã chụp.

  • cài đặt Adobe IFilter
  • Made chắc chắn SQL Server Daemon dịch vụ đầy đủ chữ đang chạy
  • Added con đường môi trường đến thư mục bin PDF Lọc Adobe
  • Ran kịch bản dưới đây để thiết lập các IFilter mới và đảm bảo rằng nó là hoạt động

    EXEC sp_fulltext_service @action='load_os_resources', @value=1; -- update os resources 
    EXEC sp_fulltext_service 'verify_signature', 0 -- don't verify signatures 
    EXEC sp_fulltext_service 'update_languages'; -- update language list 
    EXEC sp_fulltext_service 'restart_all_fdhosts'; -- restart daemon 
    EXEC sp_help_fulltext_system_components 'filter'; -- view active filters 
    
  • Tạo chỉ mục toàn văn trên FileStream ta ble tôi muốn index

    CREATE FULLTEXT INDEX on local.FILE_REPOSITORY 
    (DOCUMENT TYPE COLUMN FILE_EXTENSION) 
    Key Index PK_File_Repository ON 
    (FileSearchCat, FILEGROUP [PRIMARY]); 
    GO 
    
  • Catalogue Rebuilt

    ALTER FULLTEXT CATALOG FileSearchCatREBUILD WITH ACCENT_SENSITIVITY=OFF; 
    
  • Ran một truy vấn để xem nếu chỉ số đang làm việc

    select * 
    from local.FILE_REPOSITORYwhere freetext(DOCUMENT, '25678') 
    

Không trả lại bất kỳ kết quả cho PDF, nhưng hoạt động tốt cho từ (docx)?

Tôi đang làm gì sai?

Trả lời

3

Ok vì vậy tôi figured it out .... Tôi cần thiết để chạy các bước sau:

EXEC sp_fulltext_service @action='load_os_resources', @value=1; -- update os resources 
EXEC sp_fulltext_service 'verify_signature', 0 -- don't verify signatures 
EXEC sp_fulltext_service 'update_languages'; -- update language list 
EXEC sp_fulltext_service 'restart_all_fdhosts'; -- restart daemon 
EXEC sp_help_fulltext_system_components 'filter'; -- view active filters 

Nhưng cũng cần thiết để chạy này !!!!

reconfigure with override 
+0

Bạn đã thử nghiệm giải pháp trên trên các bảng có dữ liệu nhị phân được lưu trữ trong cột của loại hình ảnh? Cảm ơn bạn. – Manolis