Re: variable let statements ?
Posted in 1995
}Here are a couple of convoluted questions concerning Informix 4gl. No kidding! :) }(1)Is there a way to do any type of "variable" LET statement ? } }EXAMPLE: j_num is a smallint, possible range for j_num is 1-8, } Informix Ver. 4.11/OSF/DEC ALPHA } }LET p_instruct.job,j_num USING "#","a" = p_pcssd_asps.field[14,17] } }In theory :>) this would allow the assignment of values to the fields }p_instruct.job1a,p_instruct.job2a,.....p_instruct.job8a, without }having 7 additional lines of code. Only problem is, Informix can't }handle this expression. } }(2) Does anyone know if there is any type of macro expansion planned }or currently in Informix ? }EXAMPLE: }LET l1 = }"LET p_instruct.job",j_num USING "#","a = p_pcssd_asps.field[14,17]" } }-- then }l1 }-- OR }execute l1 }-- something along those lines ? } }Thanks in advance for any help,alternatives,options or general }discussion. I hate to sound negative, but I think you need to change your mindset... :) Maybe you could write your own macro expander? It's difficult to offer suggestions without really knowing what you want to do...there may be other options depending on the goal you want to achieve... HTH. -- Cheers, Billy ----------------------------------------------------------------------------- INCLUDE "Disclaimer.4gh" -- my opinions are INCLUDE "FlamesToDevNull.4gh" -- flamers, eat my shorts! INCLUDE "CaveatEmptor.4gh" -- take my advice at your own risk INCLUDE "ThirtySomething.4gh" -- header file for this class -- Written by : Billy Wheeler, Date: today -- Copyright (c) 1995, The West Solutions Group