Skip to content

Commit 703bc14

Browse files
author
Michael Meskes
committed
Fixed incorrect description of EXEC SQL VAR command.
Thanks to MauMau <maumau307@gmail.com> for finding and fixing this.
1 parent ad4c625 commit 703bc14

File tree

1 file changed

+7
-5
lines changed

1 file changed

+7
-5
lines changed

doc/src/sgml/ecpg.sgml

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -7675,9 +7675,9 @@ VAR <replaceable>varname</replaceable> IS <replaceable>ctype</replaceable>
76757675
<title>Description</title>
76767676

76777677
<para>
7678-
The <command>VAR</command> command defines a host variable. It
7679-
is equivalent to an ordinary C variable definition inside a
7680-
declare section.
7678+
The <command>VAR</command> command assigns a new C data type
7679+
to a host variable. The host variable must be previously
7680+
declared in a declare section.
76817681
</para>
76827682
</refsect1>
76837683

@@ -7709,8 +7709,10 @@ VAR <replaceable>varname</replaceable> IS <replaceable>ctype</replaceable>
77097709
<title>Examples</title>
77107710

77117711
<programlisting>
7712-
EXEC SQL VAR vc IS VARCHAR[10];
7713-
EXEC SQL VAR boolvar IS bool;
7712+
Exec sql begin declare section;
7713+
short a;
7714+
exec sql end declare section;
7715+
EXEC SQL VAR a IS int;
77147716
</programlisting>
77157717
</refsect1>
77167718

0 commit comments

Comments
 (0)