I tried this and get the same results as you. I have changed a few lines
in the function and get the same
select cj.*, charorder(aiorder),
Substr(Space(7), 1, 7 - Length(Trim(Char(aiorder)))) Concat
trim(Char(aiorder))
from cj
(although it no longer looks null after the changes)
....+....1....+....2....+....3....+....4.
AIORDER CHARORDER String Expression
27 27
******** End of data ********
Create function CharOrder
(numb DEC(8,0))
Returns char
language SQL
returns null on null input
begin
declare alpha char(7);
set alpha =
Substr(Space(7), 1, 7 - Length(Trim(Char(numb)))) Concat
trim(char(numb));
Return alpha;
End
Tried using iNav's debugger, for the first time. Either I couldn't figure
out the step, or something. I didn't get very far - and I use WDSC's
debugger normally.
Rob Berendt
As an Amazon Associate we earn from qualifying purchases.
This mailing list archive is Copyright 1997-2025 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact
[javascript protected email address].
Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.