Re: ecpg help - Mailing list pgsql-general

From Michael Meskes
Subject Re: ecpg help
Date
Msg-id 20020628131314.GC10588@feivel.credativ.de
Whole thread Raw
In response to ecpg help  ("sid@questions.com" <sbhatt@installs.com>)
List pgsql-general
On Thu, Jun 27, 2002 at 12:26:02PM -0400, sid@questions.com wrote:
> I am trying to use preprocessor directives inside the declare statements but
> its giving me compile time errors.
> What i am do is something like this
>
> EXEC SQL BEGIN DECLARE SECTION;
> char myvar[NUM];
> EXEC SQL END DECLARE SECTION;
>
> #define NUM 20 is present in one of the include files.

Please use "EXEC SQL DEFINE NUM 20" to define NUM for ECPG. ECPG does
not parse CPP directives.

Michael
--
Michael Meskes
Michael@Fam-Meskes.De
Go SF 49ers! Go Rhein Fire!
Use Debian GNU/Linux! Use PostgreSQL!



pgsql-general by date:

Previous
From: Laurent Duperval
Date:
Subject: Re: How should I do this?
Next
From: "P.J. \"Josh\" Rovero"
Date:
Subject: Re: One source of constant annoyance identified