Informix Error -2995: The form has exceeded the maximum number of tables contained in joins.
Cause and resolution
The form has exceeded the maximum number of tables contained in joins.
A limit exists on the number of tables that can be contained in one join. You must find a way to simplify the form.
Oninit® Troubleshooting Guidance
Reasons / Common Causes
-2995 fires when the number of tables involved in a form's joins exceeds the form compiler's limit — per the official guidance, this is a hard restriction on the number of tables that can be contained in one join.
- Too many tables joined together in the form, per the official guidance — the direct, only cause.
Solutions / Resolution
- Find a way to simplify the form, per the official guidance — for example, by reducing the number of tables involved in the join chain.
Examples
Reducing the number of joined tables
Move some of the joined tables' data into the calling 4GL program (queried separately) instead of joining them all within the form specification.
Diagnostic Checks
- Count the distinct tables involved in the form's joins, and reduce them if the compiler reports this limit exceeded.
Related Errors / Related Topics
- -2994 — "The form has exceeded the maximum number of joins between tables." A related join-limit error, about the number of joins rather than the number of tables involved.
The form's joins involve too many tables — simplify the form to reduce the table count.