@@ -204,8 +204,8 @@ SELECT clean_emp();
204
204
205
205
<para>
206
206
If an argument is of a composite type, then the dot notation,
207
- e.g., <literal>argname. fieldname</literal> or
208
- <literal>$1.fieldname</literal>, can be used to access attributes of the
207
+ e.g., <literal><replaceable> argname</>.<replaceable> fieldname</> </literal> or
208
+ <literal>$1.<replaceable> fieldname</> </literal>, can be used to access attributes of the
209
209
argument. Again, you might need to qualify the argument's name with the
210
210
function name to make the form with an argument name unambiguous.
211
211
</para>
@@ -527,7 +527,8 @@ LINE 1: SELECT new_emp().name;
527
527
Another option is to use
528
528
functional notation for extracting an attribute. The simple way
529
529
to explain this is that we can use the
530
- notations <literal>attribute(table)</> and <literal>table.attribute</>
530
+ notations <literal><replaceable>attribute</>(<replaceable>table</>)</>
531
+ and <literal><replaceable>table</>.<replaceable>attribute</></>
531
532
interchangeably.
532
533
533
534
<screen>
@@ -1305,12 +1306,15 @@ CREATE FUNCTION test(smallint, double precision) RETURNS ...
1305
1306
<para>
1306
1307
A function that takes a single argument of a composite type should
1307
1308
generally not have the same name as any attribute (field) of that type.
1308
- Recall that <literal>attribute(table)</literal> is considered equivalent
1309
- to <literal>table.attribute</literal>. In the case that there is an
1309
+ Recall that <literal><replaceable>attribute</>(<replaceable>table</>)</literal>
1310
+ is considered equivalent
1311
+ to <literal><replaceable>table</>.<replaceable>attribute</></literal>.
1312
+ In the case that there is an
1310
1313
ambiguity between a function on a composite type and an attribute of
1311
1314
the composite type, the attribute will always be used. It is possible
1312
1315
to override that choice by schema-qualifying the function name
1313
- (that is, <literal>schema.func(table)</literal>) but it's better to
1316
+ (that is, <literal><replaceable>schema</>.<replaceable>func</>(<replaceable>table</>)
1317
+ </literal>) but it's better to
1314
1318
avoid the problem by not choosing conflicting names.
1315
1319
</para>
1316
1320
@@ -2818,7 +2822,7 @@ HeapTuple heap_form_tuple(TupleDesc tupdesc, Datum *values, bool *isnull)
2818
2822
HeapTuple BuildTupleFromCStrings(AttInMetadata *attinmeta, char **values)
2819
2823
</programlisting>
2820
2824
to build a <structname>HeapTuple</> given user data
2821
- in C string form. <literal >values</literal > is an array of C strings,
2825
+ in C string form. <parameter >values</parameter > is an array of C strings,
2822
2826
one for each attribute of the return row. Each C string should be in
2823
2827
the form expected by the input function of the attribute data
2824
2828
type. In order to return a null value for one of the attributes,
0 commit comments