prepare,declare,open,fetch-PROBLEM FOUND-Ri...ght
Posted in 1996
For anyone interested. . .
Regarding my earlier postings with problems using
prepare, declare, open, fetch , coding method
MY problems have NOTHING to do with this coding method.
No one has been able to offer any insight into the symptoms
regarding this problem that manfests itself into fetch's that
don't work.
I FOUND OUT HOW TO MAKE THE PROGRAM WORK. BUT I DON'T KNOW WHY.
The program has a subroutine that includes the following:
foreach
foreach
end foreach
end foreach
there is lots of stuff in the foreach loops.
I did find that including this
create temp table calc_method_set(lab_case_id integer,
person_id integer,
system char(8),
relationship char(3))
directly after the "first foreach" causes these bizarre problems.
Taking the create out fixes them.
IF I PUT the "create table" in a function and call IT after the
first foreach the PROGRAM WORKS fine.
I kept the .ec and .c files from before/after and did diffs. There
is nothing significant (that I can determine) in the code being generated.
I am using 4.12.UE1 by the way.
This is not the first time in the last 5-6 years that I have found
"placement" problems with various 4GL code as a result of bugs.
Now the problem is to try and find what bug it is.
--
Michael J. Kuhn Computer Systems Consultant phone:410-254-7060
Email: mkuhn@csd.clark.net, csd@clark.net
mkuhn@rhlab.com
c/o Baltimore Rh Typing Laboratory, Inc. phone:410-225-9595