Informix Error -128
-128 ISAM error: no logging.
The ISAM processor was called for a function that requires a transaction log, but none exists for this file. For C-ISAM programs, review the creation of the data file. Before the program uses functions such as isbegin, it must set up a log using islogopen. For SQL products, this database does not support transaction logging. If you are using the database server, have the database server administrator enable logging for this database. Otherwise, use the START DATABASE statement to begin transaction logging. In all cases, start logging only immediately after the database has been fully backed up.
Oninit® Troubleshooting Guidance
Reasons / Common Causes
-128 is close enough to -122 ("transaction not available") that the two are easy to confuse — for SQL products, the official text for both is essentially the same condition (the database doesn't support transaction logging) reached through different function calls. The distinction that actually matters is on the C-ISAM side:
- -122 fires when a file was opened without the
ISTRANSflag, but something asked to mark a transaction boundary specifically on that file. - -128 fires when no log has been established for the process at all —
islogopen(), the more fundamental setup step that creates the log itself, was never called before something needed it.
For C-ISAM programs:
islogopen()was never called before a function requiring a transaction log (such asisbegin()) was used. This is a setup-ordering bug: the log needs to be established first, independent of and prior to settingISTRANSon individual file opens.
For SQL products:
- The database doesn't support transaction logging at all — the same underlying condition -122 describes on the SQL side. Whether a given operation surfaces as -122 or -128 depends on exactly which function triggered the check, not on a meaningfully different root cause.
- An environment mismatch — code developed and tested against a logged database, deployed against an unlogged one, exactly as with -122.
- A database that had logging disabled between when the application was designed and when it actually runs in a specific environment.
Solutions / Resolution
For C-ISAM programs:
- Call
islogopen()to establish the log before any function that requires one. This is a prerequisite to, and distinct from, settingISTRANSon individual file opens (-122's fix) — review initialization order to confirm the log itself is set up first.
For SQL products:
- Have the database administrator enable logging for the database, or use
START DATABASEto begin transaction logging — the same fix as -122. - Start logging only immediately after the database has been fully backed up. The official guidance repeats this sequencing point for -128 exactly as it does for -122 — it's not optional, and it's the same reasoning: logging without a backed-up baseline doesn't give you a meaningful recovery point.
- Standardize logging configuration across environments, as with -122, so application code's assumptions about transaction support hold everywhere it runs.
- If both -122 and -128 appear on the same database, treat it as one root cause (transaction logging simply isn't configured) rather than debugging each code as a separate problem.
Examples
Missing islogopen() before isbegin()
/* No islogopen() call anywhere before this */
isbegin();
/* -128: there is no log established for this process at all */
Fix:
islogopen("translog.dat"); /* establish the log first */
isbegin(); /* now valid */
The same unlogged-database condition, different trigger
DATABASE mydb; -- mydb has no transaction logging
SELECT some_function_requiring_log_metadata();
-- -128: same underlying cause as -122's BEGIN WORK example,
-- reached through a different function
The fix is identical to -122's: back up the database, then enable logging.
Diagnostic Checks
- Check whether the database has logging enabled:
SELECT is_logging FROM sysmaster:sysdatabases WHERE name = 'mydb'; - For C-ISAM, review the call order in the program's initialization — confirm
islogopen()runs, and succeeds, before any function requiring a log. - Compare configuration across environments if this appeared in one but not another running the same code.
- If -122 has also appeared on the same database, treat the investigation as one problem (missing/disabled logging), not two.
Related Errors / Related Topics
- -100 — "ISAM error: duplicate value for a record with unique key." The other foundational ISAM-level error in this family.
- -122 — "ISAM error: transaction not available." The closest sibling — functionally the
same underlying condition for SQL products; on the C-ISAM side, -122 is a missing
ISTRANSon a specific file's open, while -128 is a missingislogopen()for the log itself.
If you're seeing -128, check whether -122 has also come up on the same database or file — they usually share one root cause.