×
The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.
On 12-May-2016 15:45 -0500, Graves, Chuck wrote:
On Thursday, May 12, 2016 4:03 PM Graves, Chuck wrote:
Is there a "trick" to programming a long complex (6000 character)
SQL statement in RPG?
We keep getting a "variable truncated" error message.
<<SNIP>> The error is on the compile. <<SNIP>>
Seems likely the error is not with a variable, but with a /literal/
specification [being assigned to a variable], and thus one of:
• QRG4173 30 Literal length exceeds maximum and is truncated at
maximum.
• RNF0269 20 Character literal is too long; literal truncated.
One likely resolution is to define the statement as static instead of
assigning the value to a variable.
Another might be to concatenate multiple literals; i.e. instead of
just one assignment such as
stmt='one very long literal';
use multiple statements with shorter literals:
stmt='one';stmt+=' very';stmt+=' long';stmt+=' literal';
Or as dlclark mentioned
[
http://archive.midrange.com/rpg400-l/201605/msg00130.html], be sure
that a statement that has been /beautified/ on successive lines does not
include all of the white-space; i.e. choose the line-continuation that
maintains a valid statement while excluding any extraneous blanks.
As an Amazon Associate we earn from qualifying purchases.
This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact
[javascript protected email address].
Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.