Informix Error -256
-256 Transaction not available.
You cannot begin a transaction in this database because it does not have a transaction log. In order to support transactions, you must start a transaction log. Refer to your Administrator's Guide for information on how to start a transaction log.
Oninit® Troubleshooting Guidance
Reasons / Common Causes
-256 is the SQL-level form of the same condition -122 describes in more depth: the database
doesn't have a transaction log, so BEGIN WORK can't be executed at all.
- The database was created without transaction logging enabled, and never had logging added since.
- An environment mismatch — code developed and tested against a logged database, deployed against an unlogged one.
- Logging that was disabled since the application was originally designed.
Solutions / Resolution
See -122 for the full treatment, including the critical sequencing point:
- Have the database administrator enable logging, or use
START DATABASE ... WITH LOG. - Start logging only immediately after a full backup — per -122's own emphasis, this sequencing isn't optional.
- Standardize logging configuration across environments to prevent this kind of mismatch surfacing only in specific deployments.
Examples
See -122's examples for the full backup-then-enable-logging sequence — it applies here without modification.
Diagnostic Checks
- Check whether the database has logging enabled:
SELECT is_logging FROM sysmaster:sysdatabases WHERE name = 'mydb'; - Compare configuration across environments if this appeared in one but not another running the same code.
Related Errors / Related Topics
- -122 — "ISAM error: transaction not available." The fuller treatment of this exact condition — see there for the complete guidance, including the backup-before-logging sequencing requirement.
- -128 — "ISAM error: no logging." A closely related sibling, reached through a slightly different function but the same underlying missing-logging condition.
This is the same underlying condition as -122 — refer there for the complete guidance.