Concatenating strings in SPL
Posted in 1995
Trying to write a piece of SPL that goes something like LET p_bigstring = a || b || c || d || e || ...... ; If any one of those source variables is NULL, the engine truncates the whole thing at that point. As though it's getting mixed up at finding a terminating character at that point or something. So my client's tried re-writing it as ... IF c != " " THEN -- Kicks out nulls as well LET p_bigstring = p_bigstring || c; END IF; ... .. but now each time you try to append to p_bigstring like this, it takes all the trailing blanks with it and effectively loses 'c'. (Or b, d, e...) Questions: - Anyone seen the apparent 'Null Terminator' bug? Any workarounds? - Does SPL have any equivalent of CLIPPED? Is it expected to in a future release? Client is currently on 5.03 OnLine on HP kit. akent@cix.compulink.co.uk (Andy Kent) ------------------------------------------------ Freelance Informix Database Specialist, Redland, Bristol, England