Please Help

From: "Robert Sherry" <rsherry8(at)comcast(dot)net>
To: <pgsql-general(at)postgresql(dot)org>
Subject: Please Help
Date: 2008-12-09 03:11:05
Message-ID: 20081209031111.5BC8364FC4E@mail.postgresql.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

I am trying to get the following program to compile the following program
with Embedded SQL Processor:

#include <stdio.h>

main()

{

printf( "I am alive\n" );

#if 0

EXEC SQL CONNECT TO DEFAULT;

#endif

printf( "status is %d\n", sqlca.sqlcode );

}

I am doing this as a test that Postgres is properly installed on my system.
Here is how I compile the file (prog1.pgc):

INCDIR="/cygdrive/c/Program Files/PostgreSQL/8.3/include"

LIBDIR="/cygdrive/c/Program Files/PostgreSQL/8.3/lib"

ecpg prog1.pgc

cc -g -I "/cygdrive/c/Program Files/PostgreSQL/8.3/include" prog1.c

cc -g -o prog1 prog1.o -L "/cygdrive/c/Program Files/PostgreSQL/8.3/lib"
-lecpg

The result is that a get an undeclared identifier of: _ECPGget_sqlca from
the linker. I am hoping that somebody can tell me what I am doing

wrong.

Thanks

Bob Sherry

Browse pgsql-general by date

  From Date Subject
Next Message Rich Shepard 2008-12-09 03:17:44 Re: Problems With Bad PID and Missing Socket -- FIXED
Previous Message Klint Gore 2008-12-09 02:49:35 Re: Want quit milis