Search IBM i Services
search_ibmi_servicesSearch IBM i SQL services in QSYS2.SERVICES_INFO to find views, functions, and procedures by keyword, category, or example. Use before writing SQL to avoid guessing names and parameters.
Instructions
Find IBM i SQL services (views, table functions, procedures, and more in QSYS2 and SYSTOOLS) in the catalog QSYS2.SERVICES_INFO, with the release that added each one and an example query. Call it before writing SQL that uses an IBM i service, instead of guessing names and parameters. With no query and no category, it lists the categories with a count each. This tool only reads the catalog. Running an example with execute_query still needs the IBM i authority the service documents and, when QUERY_ALLOWED_SCHEMAS is set, the service's schema in that list. Table functions must be qualified, as in TABLE(QSYS2.ACTIVE_JOB_INFO(DETAILED_INFO => 'NONE')), with plain values as arguments.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| limit | No | Maximum services to return. Capped by QUERY_MAX_LIMIT. | |
| query | No | Keywords, all of which must appear in the service name or category (case-insensitive). Example: "journal entries" | |
| category | No | Exact category, such as JOURNAL, SECURITY, or WORK MANAGEMENT. Call with no arguments to list them. | |
| include_example | No | Include the example query for each service. Default true. | |
| search_examples | No | Also match keywords against the example queries. Default false. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| data | No | ||
| count | No | ||
| error | No | ||
| success | Yes | ||
| truncated | No | ||
| categories | No |