Re: [HACKERS] Patch for user-defined C-language functions - Mailing list pgsql-hackers

From Andreas Zeugswetter
Subject Re: [HACKERS] Patch for user-defined C-language functions
Date
Msg-id 37DDFCD9.41DB3DA7@telecom.at
Whole thread Raw
Responses Re: [HACKERS] Patch for user-defined C-language functions  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-hackers
> Postgresql operator with the following syntax
> 
> CREATE FUNCTION mytype3 ( mytype2 )
>        RETURNS mytype3
>        AS 'mytypes.so', 'mytype2_to_mytype3'
>        LANGUAGE 'C'
> 
> The syntax for the AS clause, which was 'AS <link-file>' becomes 
>     
>     AS <link_file>[, <link_name>]

Sounds great !

But I think the intuitive Syntax in SQL would use ():

CREATE FUNCTION mytype3 ( mytype2 )      RETURNS mytype3      AS 'mytypes.so(mytype2_to_mytype3)'      LANGUAGE 'C'

Syntax:AS <link_file>[(symbol_name)]

This is also how Illustra and now Informix does it.
(Instead of AS they say EXTERNAL NAME)

Andreas


pgsql-hackers by date:

Previous
From: Thomas Lockhart
Date:
Subject: Re: [HACKERS] Is "isolation" a restricted word?
Next
From: "Ansley, Michael"
Date:
Subject: RE: [HACKERS] Status report: long-query-string changes