GroupDocs.Search for Node.js via Java

Perform boolean logic searches

With GroupDocs.Search for Node.js via Java, you can create advanced search queries using boolean operators (AND, OR, NOT) seamlessly within your Node.js environment.

How to search in PDF documents using boolean operators

GroupDocs.Search allows you to search content in PDF files effectively. With boolean logic, you can refine your search queries in Node.js via Java applications for improved accuracy.

  1. Set up the folder to store the search index.
  2. Select the folder containing PDF files for the search.
  3. Run the search query and retrieve results.
  4. Process and analyze the search results.
const searchLib = require('@groupdocs/groupdocs.search')

// Set the location for the index folder
const index = new searchLib.Index("c:/MyIndex");

// Specify the folder containing documents to search
index.add("c:/MyDocuments");

// Execute a search query with advanced logic
const result = index.search("lorem AND impsum");
npm i @groupdocs/groupdocs.search
click to copy
copied
More examples Documentation

Powerful tools for document search and indexing

GroupDocs.Search for Node.js via Java streamlines text search and indexing for over 70 file types, helping you find and manage information faster and with precision.

Key features of GroupDocs.Search

Enhanced text search

Find text quickly across various formats such as PDFs, Word documents, presentations, and spreadsheets. Use features like exact matches, wildcard searches, and fuzzy search for precise results.

Efficient data indexing

Build and manage indexes to speed up searches in large document collections. Indexing ensures fast and structured access to your data.

Multilingual support

Search in documents written in over 80 languages. Morphological support and keyboard layout compatibility enhance search results in different languages.

Flexible search settings

Customize your search by enabling case sensitivity, applying date filters, or skipping specific words and data during indexing.

Example of advanced boolean search

This example demonstrates how to create Boolean-based queries for searching content in PDF documents.

JavaScript

const searchLib = require('@groupdocs/groupdocs.search')

// Define the folder for the search index
const index = new searchLib.Index("c:/MyIndex");
    
// Provide the location of the documents to search
index.add("c:/MyDocuments");

// Build a query using Boolean operators
const wordQuery1 = searchLib.SearchQuery.createWordQuery("Lorem");
const wordQuery2 = searchLib.SearchQuery.createWordQuery("ipsum");
const booleanQuery = searchLib.SearchQuery.createAndQuery(wordQuery1, wordQuery2);

// Retrieve search results
const result = index.search(booleanQuery);

// Process and use the search results
console.log('Documents: ' + result.getDocumentCount());
console.log('Occurrences: ' + result.getOccurrenceCount());
npm i @groupdocs/groupdocs.search
click to copy
copied
More examples Documentation

What is GroupDocs.Search?

GroupDocs.Search for Node.js via Java is a robust tool for searching and indexing text within documents. It supports over 70 formats like PDF, Word, Excel, PowerPoint, images, and ZIP files, making it easy to process large amounts of information efficiently.
Learn more
About illustration

Ready to get started?

Download GroupDocs.Search for free or get a trial license for full access!

Useful resources

Explore documentation, code samples, and community support to enhance your experience.

Key capabilities of GroupDocs.Search

Unlock advanced, efficient, and customizable search features.

Search popular document formats

GroupDocs.Search supports over 70 file formats, providing flexible search rules and efficient indexing to save time and effort.

Temporary license tips

1
Sign up with your work email.
Free mail services are not allowed.
2
Use Get a temporary license button on the second step.
 English