>From: uunet!mprgate.mpr.ca!sandie (Bert Sandie)
>Subject: Declaring Host Variables with STRUCT
>Date: 16 Sep 92 19:38:52 GMT
>X-Informix-List-Id: <news.1818>
>
> ...
>
>The reason I want to use the first method is that I have existing
>structures which have many embedded STRUCT and I do not want to
>have to redeclare these in ESQL/C for a second time.
Ah, Easy, I thought. No, better check it. Checked it, and it didn't
work, mainly because I was using a 4.00 ESQL compiler in which temp is
a reserved word. When tested on a machine with 5.00, it worked OK.
This works under 5.00 (and probably 4.10, but I haven't proved that!).
File temp.h:
struct temp
{
char t_l[15];
char t_f[15];
};
File temp.ec:
EXEC SQL BEGIN DECLARE SECTION
$include "temp.h";
struct temp temp1;
EXEC SQL END DECLARE SECTION
Yours,
Jonathan Leffler (johnl@obelix.informix.com) #include <disclaimer.h>