Does your SRF function allow to return a setof composite data type using C function? If so, how can I write such that C function? I couldn't find any example or explanation so far. You referred dblink, but in my understanding it does not have any function that returns a setof composite data type. -- Tatsuo Ishii
> Attached is the script I've been using to test as I go. It shows the > usage of SRFs in a variety of situations (note that the C function tests > require contrib/dblink installed). There's also a description in one of > my earlier posts. Here is a recap, edited to the latest reality: > > How it currently works: > ----------------------- > 1. The SRF may be either marked as returning a set or not. A function > not marked as returning a set simply produces one row. > > 2. The SRF may either return a base data type (e.g. TEXT) or a composite > data type (e.g. pg_class). If the function returns a base data type, the > single result column is named for the function. If the function returns > a composite type, the result columns get the same names as the > individual attributes of the type. > > 3. The SRF may be aliased in the FROM clause, but it also be left > unaliased. If a function is used in the FROM clause with no alias, the > function name is used as the relation name. > > Hope that's a start. > > Thanks, > > Joe ---------------------------(end of broadcast)--------------------------- TIP 2: you can get off all lists at once with the unregister command (send "unregister YourEmailAddressHere" to [EMAIL PROTECTED])