×
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.
I've been working around this for a very long time by using literals or just loading the constant into a variable. I was just hoping there was a compiler setting I was missing.
Thanks guys
-----Original Message-----
From: Brian Parkins [mailto:goodprophet.bp@xxxxxxxxx]
Sent: Tuesday, December 20, 2016 3:51 AM
To: RPG programming on the IBM i (AS/400 and iSeries) <rpg400-l@xxxxxxxxxxxx>
Subject: Re: Embedded SQL & named constants
Justin asked:
Is it possible to use named constants as variables in embedded SQL statements? I've tried but never been able to make it work.
From the ILE RPG section of the Embedded SQL Programming manual (V7R3):
Declaring host variables in ILE RPG applications that use SQL ==================================================
The SQL ILE RPG precompiler only recognizes a subset of valid ILE RPG declarations as valid host variable declarations.
Most variables defined in ILE RPG can be used in SQL statements. A partial listing of variables that are not supported includes the following:
. . .
- Named constants
. . .
Brian.
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.