Saved searches are arguably the most powerful native tool in Oracle NetSuite. They allow you to query virtually any data in your system, create real-time reports, populate dashboards, drive automated workflows, and much more. Whether you're a new NetSuite user or an experienced administrator, mastering saved searches is essential.
What Is a Saved Search?
A saved search is a reusable query that pulls specific data from your NetSuite account based on criteria you define. Think of it as a customizable report that updates in real-time. Unlike standard reports, saved searches give you complete control over what data appears, how it's filtered, sorted, and displayed.
Saved searches can be used for:
- Creating custom reports and KPI dashboards
- Populating list views and portlets on your dashboard
- Driving workflow conditions and SuiteScript logic
- Feeding data into scheduled processes and mass updates
- Building dynamic dropdown lists on custom forms
Step 1: Navigate to the Saved Search Page
To create a new saved search, navigate to Reports > Saved Searches > All Saved Searches > New. Alternatively, you can type "saved search" in the global search bar and select "New Saved Search" from the results.
You'll be presented with a list of search types. The search type determines what kind of records you'll be querying. Common types include:
- Transaction – Sales orders, invoices, purchase orders, journal entries, etc.
- Customer – Customer records and related data
- Item – Inventory items, service items, non-inventory items
- Employee – Employee records
- Vendor – Vendor/supplier records
Select the appropriate search type for your needs. For this guide, we'll create a Transaction search to find all open invoices.
Step 2: Configure Basic Settings
On the saved search form, start with the basics:
- Search Title – Give your search a descriptive name, e.g., "Open Invoices by Customer"
- ID – NetSuite auto-generates an ID (e.g., customsearch_open_invoices). You can customize this for easier reference in scripts.
- Public – Check this to make the search available to other users (based on their role permissions)
Step 3: Define Your Criteria
The Criteria tab is where you filter your data. This is equivalent to a WHERE clause in SQL. You can add standard filters and formula-based filters.
For our open invoices example, add these criteria:
- Type is Invoice
- Status is Invoice : Open
- Main Line is True (to avoid duplicate lines from multi-line transactions)
You can also use the Use Expressions checkbox to combine criteria with AND/OR logic. For example: (Type is Invoice AND Status is Open) OR (Type is Invoice AND Status is Partially Paid).
Formula Criteria
For advanced filtering, use formula criteria. Select "Formula (Numeric)" and enter a formula that returns 1 for matching records. For example, to find invoices older than 30 days:
CASE WHEN {daysopen} > 30 THEN 1 ELSE 0 END
Set the formula value to "is 1" to filter only matching records.
Step 4: Add Result Columns
The Results tab defines which columns appear in your search output. Click "Add" to insert columns one at a time, or "Add Multiple" to quickly select several fields.
For our open invoices search, add these result columns:
- Date
- Document Number
- Name (Customer)
- Amount
- Amount Remaining
- Days Open
- Currency
Summary Types
Each result column can have a Summary Type: Group, Sum, Count, Minimum, Maximum, or Average. When you use summary types, your search becomes an aggregated report. For example, setting Name to "Group" and Amount Remaining to "Sum" will show total outstanding amount per customer.
Formula Columns
Add calculated fields using formula columns. Select "Formula (Currency)" or "Formula (Text)" and enter your formula. For example, to categorize aging:
CASE
WHEN {daysopen} <= 30 THEN 'Current'
WHEN {daysopen} <= 60 THEN '31-60 Days'
WHEN {daysopen} <= 90 THEN '61-90 Days'
ELSE 'Over 90 Days'
END
Step 5: Configure Sorting
On the Results tab, use the Sort column to define how your results are ordered. You can sort by any result column in ascending or descending order. For our invoice search, sort by "Days Open" in descending order to see the oldest invoices first.
Step 6: Set Up Available Filters
The Available Filters tab lets you add runtime filters that users can change when viewing the search. This is incredibly useful for making searches flexible. Add filters like Date range, Customer, or Subsidiary so users can narrow results without editing the search definition.
Step 7: Customize the Display
On the Highlighting tab, you can add conditional formatting. For example, highlight rows in red where Amount Remaining is greater than 10,000, or where Days Open exceeds 90. This makes it easy to spot critical items at a glance.
Best Practices for Saved Searches
- Use Main Line filter – For transaction searches, always consider whether you need the main line (header) or individual lines. Set Main Line to True for summary data, or False/leave blank for line-level detail.
- Name searches consistently – Use a naming convention like "YRK - Open Invoices by Customer" to organize and find searches easily.
- Limit results – Use the "Results" count limit to prevent slow-loading searches with thousands of results.
- Use Available Filters – Make searches reusable by adding filters rather than hard-coding criteria.
- Test with "Preview" – Always preview your search before saving to verify results are correct.
- Document custom formulas – Add comments using the Description field to explain complex formula logic for future reference.
Common Saved Search Formulas
Here are some commonly used formulas in saved searches:
| Purpose | Formula |
|---|---|
| Full name | {firstname} || ' ' || {lastname} |
| Days since created | ROUND(SYSDATE - {datecreated}) |
| Fiscal year | TO_CHAR({trandate}, 'YYYY') |
| Month name | TO_CHAR({trandate}, 'Month') |
| Conditional text | CASE WHEN {amount} > 0 THEN 'Credit' ELSE 'Debit' END |
Next Steps
Once you're comfortable with basic saved searches, explore advanced topics like using saved searches in workflows, embedding them in dashboards as portlets, or referencing them in SuiteScript for automation. Saved searches are the foundation of NetSuite reporting and customization—mastering them will dramatically improve your productivity.
Need help building complex saved searches or optimizing your NetSuite reporting? Contact YRK Consulting for expert guidance.