Re: ESQL/C: use of 'like' in declare
Posted in 2000
Sunil Bhaskarla wrote:
> Why cant I use this statement below in esql/c?
> ...
> $declare tb_setup like setup;
> - OR -
> $declare hv_cxm_lops integer;
> ...
Because it isn't supported syntax.
DECLARE is an ESQL/C statement used to declare a cursor for a SELECT,
INSERT or
EXECUTE PROCEDURE statement.
Even if you changed DECLARE to DEFINE to match what I4GL does, you would
then find
that ESQL/C is not I4GL and does not accept the notation "xyz LIKE
Table.Column". In fact,
unlike the I4GL compiler, the ESQL/C compiler never accesses the
database at compile time.
> Are there any alternatives other than using sqlda descriptors?
sqlda descriptors are not a solution to this problem.
--
Jonathan Leffler (jleffler@informix.com, jleffler@earthlink.net)
Guardian of DBD::Informix v0.62 -- see http://www.perl.com/CPAN
#include <disclaimer.h>