Highlighted
Absent Member.
Absent Member.
299 views

[archive] ESQL and EXIT PROGRAM

[Migrated content. Thread originally posted on 22 October 2007]

This is my first time.

I'm using AcuSQL and i have this problem :

If i don't insert "accept omitted" before "exit program" i have a unexpected return at calling program with bad error.

Sorry for my english.
0 Likes
4 Replies
Highlighted
Absent Member.
Absent Member.

RE: [archive] ESQL and EXIT PROGRAM

It is always good to see some code. Can you provide example code that illustrates the problem?
0 Likes
Highlighted
Absent Member.
Absent Member.

RE: [archive] ESQL and EXIT PROGRAM

It is always good to see some code. Can you provide example code that illustrates the problem?


I have used the acucorp example but i have put "exit program" before "stop run" because it is called by another program.

If i comment the last accept omitted the program do all required instruction into database but when return the control to calling program it return in unexpected position.

So : I must put the ACCEPT OMITTED (BEFORE TIME 1 for no keyboard request) before "exit program" in called program.

Thanks so much
0 Likes
Highlighted
Absent Member.
Absent Member.

RE: [archive] ESQL and EXIT PROGRAM

The provided example shows not ACCEPT OMITTED BEFORE TIME, nor is there any EXIT PROGRAM before the STOP RUN.

I notice there is a mixture of SECTION and paragraph, I'd suggest for consistency, you go for one, not both styles.

Also, rather than doing a mixture of EXIT PROGRAM and STOP RUN, why not just resolve to GOBACK (except for error conditions, where you clearly want to halt anyway).
0 Likes
Highlighted
Absent Member.
Absent Member.

RE: [archive] ESQL and EXIT PROGRAM

I try your suggestion,but it doesn't seem to work..
I try to post another example,maybe it would be easier to understand.
the first program PROVASQL.COB call the other and when it comes back show four lines on the screen.
If we use ACCEPT OMITTED BEFORE TIME in the first program it's all OK,but if we take it away(as it's in the example)we have an error when the focus come back to the first program!
I hope i could explain the problem.
thanks
0 Likes
The opinions expressed above are the personal opinions of the authors, not of Micro Focus. By using this site, you accept the Terms of Use and Rules of Participation. Certain versions of content ("Material") accessible here may contain branding from Hewlett-Packard Company (now HP Inc.) and Hewlett Packard Enterprise Company. As of September 1, 2017, the Material is now offered by Micro Focus, a separately owned and operated company. Any reference to the HP and Hewlett Packard Enterprise/HPE marks is historical in nature, and the HP and Hewlett Packard Enterprise/HPE marks are the property of their respective owners.