summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTom Lane1999-09-11 22:02:51 +0000
committerTom Lane1999-09-11 22:02:51 +0000
commita7fd74edb39abaa9ddd52b735778588a2fb65a52 (patch)
treec9612152e461e7a02b89ad4b61dc74bd5b967a63
parentb399805e221b5407f4f459c41661c86bb580680f (diff)
Update protocol doc to emphasize that backend can return
arbitrarily long strings, and frontends should cope gracefully. Goes along with long query and long error message changes...
-rw-r--r--doc/src/sgml/protocol.sgml17
1 files changed, 10 insertions, 7 deletions
diff --git a/doc/src/sgml/protocol.sgml b/doc/src/sgml/protocol.sgml
index bc03ecb55f6..0416c94bad5 100644
--- a/doc/src/sgml/protocol.sgml
+++ b/doc/src/sgml/protocol.sgml
@@ -657,17 +657,20 @@ This section describes the base data types used in messages.
<ListItem>
<Para>
A conventional C '\0' terminated string with no length
- limitation. A frontend should always read the full string
- even though it may have to discard characters if its buffers
- aren't big enough.
+ limitation.
+ If <Replaceable>s</Replaceable> is specified it is the literal value.
+ Eg. String, String("user").
+</Para>
+
<Note>
<Para>
-Is 8193 bytes the largest allowed size?
+<Emphasis>There is no predefined limit</Emphasis> on the length of a string
+that can be returned by the backend. Good coding strategy for a frontend
+is to use an expandable buffer so that anything that fits in memory can be
+accepted. If that's not feasible, read the full string and discard trailing
+characters that don't fit into your fixed-size buffer.
</Para>
</Note>
- If <Replaceable>s</Replaceable> is specified it is the literal value.
- Eg. String, String("user").
-</Para>
</ListItem>
</VarListEntry>
<VarListEntry>