Re: Informix error messages
Posted in 2000
Red Valsen wrote: > What is Informix's management policy for error messages? Good question. > Do blocks of error codes represent categories of errors -- e.g., error > no.'s 2000 - > 3000 are i/o errors, etc.? Sort of. Errors up to about 199 are C-ISAM or RSAM or system errors, for example. Errors from 200 to 999 are SQL and engine internals errors. Errors from 1000 to 1199 are in another message file, and then 1200..1299 are in another file and are I4GL related, then 1300..1399 in another file, etc. Each message file has a fixed range of numbers allocated to it, and includes both the positive (messages) and negative (error messages) range. Not all error numbers in the ranges are used. > Does an error message ever change in text Yes. For example, if a new condition applies in a new server. The intent of the message is not supposed to change (and when it does, it is some sort of bug, but sometimes the old wording was buggy. And sometime the message should change (-461) but doesn't. > > or number between releases -- e.g., does error number 939 ever become > 1939 with same text? In general, no. Occasionally yes. > Is the verbiage ever changed? When necessary. > Are messages ever dropped between releases? Yes. For example, some errors are no longer generated by I4GL that once were generated by I4GL. The message text might still appear in the file, but it will never actually be used any more. Sometimes, the message text is actually dropped from the files, but not often, because... > Are numbers ever reused? Very seldom. To be precise, I believe that some error numbers from product which have been obsolete for over 10 years have been reused, but I basically failed to get some error numbers which had been obsolete for over 5 years reallocated to a separate product (D4GL) that needed them. > What is the difference between errors with hyphens and those without in > errmsg.txt? Negative numbers are errors. Positive numbers are not, in general, errors. There's at least one connectivity error that is positive (dammit -- and that is an outright bug in my book), but the majority of such messages are things like menu strings and other non-error messages. > If more than one error is returned, is the order contingent on severity? No. In general, only one message is returned. There is a secondary error number, often called the ISAM error number, which qualifies or amplifies on the main error. The only time you can get multiple errors returned other than by the ISAM error is if you are using GET DIAGNOSTICS. In that case, the errors are returned in temporal order (or reverse temporal order); they are never graded by severity. In fact, there is no concept of severity per se. > If not, is there an order of return? Last error only, except with GET DIAGNOSTICS. > Will Informix ever give us anything more for determining SQL syntax > errors other than unhelpful error no. -201? Occasionally. It depends on the nature of the error. > Does anyone have a routine to parse the error message file into unload > format? The errmsgtbl routine from iiug isn't quite robust enough. Errr...Try listiem from the IIUG software archives (Miscellaneous Routines and Utilities). That version dates back to 1995, so it won't handle D4GL files, but it will handle both the older 5.x (16-bit) error message numbers and the newer 32-bit error message numbers. And the hack for D4GL is simply that the magic number in the files is 0. -- Jonathan Leffler (jleffler@informix.com, jleffler@earthlink.net) Guardian of DBD::Informix v0.95 -- see http://www.perl.com/CPAN #include <disclaimer.h>