question on trigger

From: "rui zhong" <rick_rui(at)hotmail(dot)com>
To: rick_rui(at)hotmail(dot)com, pgsql-general(at)postgresql(dot)org, pgsql-jdbc(at)postgresql(dot)org
Subject: question on trigger
Date: 2001-06-23 23:10:58
Message-ID: F207zdgJI7fG7rIgwbO0001bf2b@hotmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general pgsql-jdbc


Hi,all:

This is my first time to use trigger. I try an example from programmer's
guide. Firstly I save the procedure named trigf.c, then i try to comlile it
by using SQL statement " create function trigf() returns opaque as
'...path_to_so' language 'c' ", then I got error message as " Load of file
/home/postgres/trigf.c failed: invalid ELF header ". I don't know how to
fix this, please help me out. Lots of thanks.

The including H file in trigf.c is :

#include "executor/spi.h" /*this is what you need to work with SPI */
#include "commands/trigger.h" /*-"- and triggers */

extern Datum trigf(PG_FUNCTION_ARGS);

PG_FUNCTION_INFO_V1(trigf);

Datum
trigf(PG_FUNCTION_ARGS)
{ ... }

Rui

_________________________________________________________________
Get your FREE download of MSN Explorer at http://explorer.msn.com

Attachment Content-Type Size
unknown_filename text/plain 0 bytes

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Daniel Åkerud 2001-06-23 23:21:38 Re: question on trigger
Previous Message Peter Eisentraut 2001-06-23 22:06:20 Re: ANSI SQL-92 Standard, for download?

Browse pgsql-jdbc by date

  From Date Subject
Next Message Daniel Åkerud 2001-06-23 23:21:38 Re: question on trigger
Previous Message Ola Sundell 2001-06-23 10:56:16 org.postgresql.Field and the originating table.