Re: HELP ON 4GL ERROR -4518
Posted in 1994
In article <3b1jgq$60n@csl2.csl-gmbh.net>,
chris@news.csl-gmbh.net (Christoph Schiffer) wrote:
> -- here is the error message
>
> -4518: The 4GL program cannot allocate any more space for temporary> string storage
>
> Does anyone have a solution to solve this
> problem without big expense ?
Sigh,
From the FAQ...
4.1.1 I keep getting -4518 errors! How can I fix this problem?
-------------------------------------------------------------
The -4518 error is usually caused by running out of a resource
known as temporary string space. Solutions include:
1) Upgrade to 4GL-RDS 4.12 or greater.
2) Compile to a "real" executable with 4GL/C, rather than RDS.
(You're less likely to hit it using 4GL/C)
3) Read Loren West's excellent description of how TSS is used
(see Appendix A)
4) Read Informix TechInfo sheet #3925 (Loren's Article). Other
-4518 related entries are 4064, 4517, and 2801.
5) Try to make do with the following information (most of which
only address the symptoms, not the causes):
This error can be caused by any of the following coding structures:
1) LET l_str = "Hello ",myfunc("World"))
2) CASE statements without an OTHERWISE # Pre-4.1
3) CASE statements that look like this: # Pre-4.11 (maybe 4.10)
CASE dummy_var
WHEN 0
.....
WHEN 1
.....
WHEN 2
.....
END CASE
instead of this:
CASE
WHEN dummy_var = 0
.....
WHEN dummy_var = 1
.....
WHEN dummy_var = 2
.....
END CASE
4) Reports with excessive string usage (ie. USING, or other literals)
One thing you can do to reduce the contents of string storage is
to assign redundant strings associated with USING to variables and
then refer to the variable:
let l_str1 = '$$$$$$$$.$$'
PRINT l_number USING l_str1
5) RETURNing large strings from functions.
6) Use of SPACE, SPACES, COLUMN, UPSHIFT, DOWNSHIFT, or WORDWRAP
7) Assignment of NULL to a string subscript:
DEFINE x, y CHAR(10)
LET y = NULL
LET x[3,5] = y
BEWARE: There seems to be a bug in 4GL/ID (4.1 at least) which causes TSS
problems to occur after the interrupt key has been pressed, which isn't very
helpful if you're trying to find TSS problems in your program!!!
--------------------------------------,-------------------------------------
Kerry Sainsbury, kerry@kcbbs.gen.nz | THE INFORMIX FAQ
Quanta Systems, Auckland, New Zealand | kcbbs.gen.nz:/informix/*
| mathcs.emory.edu:/pub/informix/faq/*
+64 9 377-4473 (work) 276-5546 (home) | quasar.ucar.edu:/?