Skip Navigation LinksALVAO 8.1ALVAO Service DeskSystem Implementation in an OrganizationFull-Text Search Skip Navigation Links. Skip Navigation Links Skip Navigation Links.


Full-Text Search

It is possible to use quick search using Full-Text Search in SD Console and SD WebApp. You need to have the Full-Text and Semantics Extractions for Search, an optional part of the SQL Database Engine, installed to use this function. This component can be added during initial installation of the MS SQL Server or can be installed later using the SQL Server installation package for any edition.

Tip:
We recommend to check whether the Full-Text Search is enabled and enable it, if necessary. This helps you optimize requests search.

Full-Text Search Enabled Check

Installation and settings can be checked using the SQL command:

IF (1 != ISNULL(fulltextserviceproperty('IsFulltextInstalled'),0)) PRINT N'FTS není nainstalováno.' ELSE
IF (1 != ISNULL((SELECT 1 FROM [dbo].[sysfulltextcatalogs] WHERE name = 'ftCatalogAlvao'),0))
PRINT N'FTS není zapnuto.' ELSE PRINT N'FTS je nainstalováno a zapnuto.'

If "FTS not installed" is returned, you need to install Full-Text and Semantics Extractions for Search and then set it up.

If "FTS not enabled" is returned, you need to set it up.

If "FTS installed and enabled" is returned, you do not need to set anything up.

Tip:
If, during upgrade to 8.1 version, there was Full-Text and Semantics Extractions for Search component installed, the Full-Text Search enabled itself by upgrade.

Full-Text Search Enabling

If Full-Text Search is not enabled by using the ALVAO database, you need to run the SQL script to enable it. This script sets the database to use database language for word inflection during search. If you want to change this language, in the following script:

DECLARE @languageLCID int; 
SELECT TOP 1 @languageLCID = lcid from master..syslanguages where langid = @@DEFAULT_LANGID; 
DECLARE @CreateFulltext nvarchar(MAX); 
SET @CreateFulltext = N'CREATE FULLTEXT CATALOG ftCatalogAlvao WITH ACCENT_SENSITIVITY = OFF AS DEFAULT; 
CREATE FULLTEXT INDEX ON tHdTicket (sHdTicket LANGUAGE '+CAST(@languageLCID AS nvarchar)+N', mHdTicketNotice LANGUAGE '+CAST(@languageLCID AS nvarchar)+N') KEY INDEX PK_tHdTicket_iHdTicketId WITH STOPLIST OFF; 
CREATE FULLTEXT INDEX ON tAct (sAct LANGUAGE '+CAST(@languageLCID AS nvarchar)+N', mActNotice LANGUAGE '+CAST(@languageLCID AS nvarchar)+N', sActFrom LANGUAGE ' 
+CAST(@languageLCID AS nvarchar)+N', sActTo LANGUAGE '+CAST(@languageLCID AS nvarchar)+N', sActToEmail LANGUAGE '+CAST(@languageLCID AS nvarchar)+N', sActFromEmail LANGUAGE ' 
+CAST(@languageLCID AS nvarchar)+N') KEY INDEX PK_tAct_iActId WITH STOPLIST OFF; 
CREATE FULLTEXT INDEX ON tDocument (sDocument LANGUAGE '+CAST(@languageLCID AS nvarchar)+N') KEY INDEX PK_tDocument_iDocumentId WITH STOPLIST OFF;'
EXECUTE sp_executesql @CreateFulltext;

replace the second line with the following:

SET @languageLCID = 1029

Replace the number 1029 with the number of national environment which language you want to use.

Then run the modified script. If you want to use the database language, do not modify anything and use the original script.

Warning:
Creation of Full-Text Search indexes is asynchronous and may load the drive significantly.
Warning:
To run this SQL script you have to be a member of sysadmin, db_owner, or db_ddladmin group.

If you want to change Full-Text Search language after its enabling, you need first to disable Full-Text Search and then enable it again for another language.

Full-Text Search Disabling

To disable Full-Text Search catalog execute the following SQL script:

DROP FULLTEXT INDEX ON tHdTicket; 
DROP FULLTEXT INDEX ON tAct; 
DROP FULLTEXT INDEX ON tDocument; 
DROP FULLTEXT CATALOG ftCatalogAlvao;

These commands remove the catalog and all the Full-Text Search indexes. After removal you can no longer use quick search.

Warning:
To run this SQL script you have to be a member of sysadmin, db_owner, or db_ddladmin group.

 

Did not find what you were looking for? Ask our technical support team.