Stefio Almeida
New Member
Hi Forum,
I am coding a allocation tool in ABL which should provide both options viz. simulation and also should allow table update.
For simulation I am using temp-tables. What i want to acheive by not having duplicate code all over my application is use the same piece of code but the table will be TEMP-TABLE if its a simulation and Actual Table if its update.
pseudo code:
I want to acheive something like this. I am running into trouble at the WHERE clause in the .i file.
If someone has tackle a similar situation like this more effectively, I'd like to know how. No need for the actual code but i'd like to know various possiblities of acheiving this.
Thanks.
I am coding a allocation tool in ABL which should provide both options viz. simulation and also should allow table update.
For simulation I am using temp-tables. What i want to acheive by not having duplicate code all over my application is use the same piece of code but the table will be TEMP-TABLE if its a simulation and Actual Table if its update.
pseudo code:
Code:
abc.p
define temp-table ttld_det like ld_det.
buffer-copy ld_det to tt_ld_det.
{alloc.i &file = "if not simul then ld_det else ttld_det" }
alloc.i
for each {&file} where ld_part = part and ld_site = site :
end.
If someone has tackle a similar situation like this more effectively, I'd like to know how. No need for the actual code but i'd like to know various possiblities of acheiving this.
Thanks.