Content-Length: 273203 | pFad | http://github.com/postgrespro/postgres/commit/d8a5608d4ac9d4b74772980666cc6626bd18c3ff

B5 psql: fix \copy stdin trailing space requirement · postgrespro/postgres@d8a5608 · GitHub
Skip to content

Commit d8a5608

Browse files
committed
psql: fix \copy stdin trailing space requirement
Previously a trailing space was required for \copy ... stdin: copy foo from stdin ; Etsuro Fujita
1 parent 601f480 commit d8a5608

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/bin/psql/copy.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -196,7 +196,7 @@ parse_slash_copy(const char *args)
196196
goto error;
197197

198198
/* { 'filename' | PROGRAM 'command' | STDIN | STDOUT | PSTDIN | PSTDOUT } */
199-
token = strtokx(NULL, whitespace, NULL, "'",
199+
token = strtokx(NULL, whitespace, ";", "'",
200200
0, false, false, pset.encoding);
201201
if (!token)
202202
goto error;
@@ -205,7 +205,7 @@ parse_slash_copy(const char *args)
205205
{
206206
int toklen;
207207

208-
token = strtokx(NULL, whitespace, NULL, "'",
208+
token = strtokx(NULL, whitespace, ";", "'",
209209
0, false, false, pset.encoding);
210210
if (!token)
211211
goto error;

0 commit comments

Comments
 (0)








ApplySandwichStrip

pFad - (p)hone/(F)rame/(a)nonymizer/(d)eclutterfier!      Saves Data!


--- a PPN by Garber Painting Akron. With Image Size Reduction included!

Fetched URL: http://github.com/postgrespro/postgres/commit/d8a5608d4ac9d4b74772980666cc6626bd18c3ff

Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy