Similarities & Differences Between DB Index, Unique Index, and Text Index in ServiceNow
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-06-2025 09:22 AM
🔷 Similarities Between DB Index, Unique Index, and Text Index in ServiceNow
Feature DB Index Unique Index Text IndexImproves Performance | ✅ | ✅ | ✅ |
Defined on Fields | ✅ | ✅ | ✅ |
Configured via Indexes Module | ✅ | ✅ | ✅ |
Used in Query Optimization | ✅ | ✅ | ✅ |
Supports Faster Data Retrieval | ✅ | ✅ | ✅ |
Can Be Created via Studio or Table Configuration | ✅ | ✅ | ✅ |
🔶 Differences Between DB Index, Unique Index, and Text Index
Feature DB Index Unique Index Text Index
Purpose | Speeds up queries on fields. | Ensures field values are unique. | Enables full-text search. |
Enforces Uniqueness | ❌ | ✅ | ❌ |
Search Type | Exact match, range. | Exact match only. | Keyword, fuzzy, partial match. |
Field Types | Any field. | Any field. | Long text fields. |
Common Use Case | Filtering, sorting, joins. | Preventing duplicates. | Searching descriptions/comments. |
Used in Global Search | ❌ | ❌ | ✅ |
Supports Multiple Fields | ✅ | ✅ | ❌ (usually single text field) |
🛠️ When to Use Each
- DB Index: Use when you have frequent queries on a field or combination of fields.
- Unique Index: Use when you need to enforce data integrity (e.g., no duplicate usernames).
- Text Index: Use when you want to enable keyword search in large text fields (Global search).
0 REPLIES 0