You can access the NetSearch Extender functionality using the db2text command.
db2text ENABLE DATABASE FOR TEXT
db2text ... connect TO database USER userID USING password
db2text ?
db2text ? command
db2text ? CREATE INDEX
db2text returns 0 if the command has been processed successfully, and 1 if the command has not been processed. Note that if there are document errors but the index still updates, the db2text command returns 0 with a warning message. Information about document errors can be found in the event table of the index.
Depending on your operating system and your active command shell, the system interprets special characters such as ?, (, ), *, !, and ". Therefore, if the command contains these characters, use quotation marks or an escape character.
db2 "SELECT * FROM sample WHERE CONTAINS (DESCRIPTION, '\"enable\"') = 1"