diff --git a/doc/src/sgml/xfunc.sgml b/doc/src/sgml/xfunc.sgml
new file mode 100644
index 7064312..cc5b5ef
*** a/doc/src/sgml/xfunc.sgml
--- b/doc/src/sgml/xfunc.sgml
*************** SELECT getname(new_emp());
*** 538,556 ****
CREATE FUNCTION tf1 (acct_no integer, debit numeric) RETURNS numeric AS $$
UPDATE bank
! SET balance = balance - $2
! WHERE accountno = $1
RETURNING balance;
$$ LANGUAGE SQL;
Here the first parameter has been given the name acct_no>,
and the second parameter the name debit>.
! So far as the SQL function itself is concerned, these names are just
! decoration; you must still refer to the parameters as $1>,
! $2>, etc within the function body. (Some procedural
! languages let you use the parameter names instead.) However,
! attaching names to the parameters is useful for documentation purposes.
When a function has many parameters, it is also useful to use the names
while calling the function, as described in
.
--- 538,580 ----
CREATE FUNCTION tf1 (acct_no integer, debit numeric) RETURNS numeric AS $$
UPDATE bank
! SET balance = balance - debit
! WHERE accountno = acct_no
RETURNING balance;
$$ LANGUAGE SQL;
Here the first parameter has been given the name acct_no>,
and the second parameter the name debit>.
! Named parameters can still be referenced as
! $n>>; in this example, the second
! parameter can be referenced as $2>, debit>,
! or tf1.debit>.
!
!
!
! If a parameter is given the same name as a column that is available
! in the query, the name will refer to the column. To explicitly
! refer to the parameter, you can qualify its name with the name of
! the containing function. For example,
!
!
! CREATE FUNCTION tf1 (accountno integer, debit numeric) RETURNS numeric AS $$
! UPDATE bank
! SET balance = balance - debit
! WHERE accountno = tf1.accountno
! RETURNING balance;
! $$ LANGUAGE SQL;
!
!
! This time, the first parameter has been given the ambiguous name
! accountno>.
! Notice that inside the function body, accountno> still
! refers to bank.accountno>, so tf1.accountno>
! must be used to refer to the parameter.
!
!
!
When a function has many parameters, it is also useful to use the names
while calling the function, as described in
.