lerg_complex_query
Combine data from multiple LERG tables with complex JOINs and filter operators. Query NPA-NXX, carrier info, and more by joining tables like lerg_6 and lerg_1 using OCN.
Instructions
Execute a complex LERG query with JOINs across multiple tables. Supports filter operators: eq, ne, gt, gte, lt, lte, like, in, isnull, isnotnull. Use this when you need to combine data from different LERG tables, such as joining NPA-NXX (lerg_6) with carrier info (lerg_1) via OCN.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| join | No | Optional JOIN clause | |
| limit | No | Max results (default 100) | |
| table | Yes | Primary table name (e.g. lerg_6) | |
| fields | No | Fields to return from primary table (e.g. ['npa','nxx','ocn','loc_name']) | |
| offset | No | Pagination offset (default 0) | |
| filters | Yes | Filter conditions (e.g. [{field:'npa', operator:'eq', value:720}]) |