diff options
author | Tom Lane <tgl@sss.pgh.pa.us> | 2009-09-21 20:10:21 +0000 |
---|---|---|
committer | Tom Lane <tgl@sss.pgh.pa.us> | 2009-09-21 20:10:21 +0000 |
commit | 923413ac6d31826bd599711962ce9cb7d51a997f (patch) | |
tree | 61538745eb89472649451470ca12011eb5392106 /src/test/regress/expected/copy2.out | |
parent | 0f427dfe5ae26f4b792f4f0b8d235dd60a1d144f (diff) | |
download | postgresql-923413ac6d31826bd599711962ce9cb7d51a997f.tar.gz |
Define a new, more extensible syntax for COPY options.
This is intentionally similar to the recently revised syntax for EXPLAIN
options, ie, (name value, ...). The old syntax is still supported for
backwards compatibility, but we intend that any options added in future
will be provided only in the new syntax.
Robert Haas, Emmanuel Cecchet
Diffstat (limited to 'src/test/regress/expected/copy2.out')
-rw-r--r-- | src/test/regress/expected/copy2.out | 33 |
1 files changed, 33 insertions, 0 deletions
diff --git a/src/test/regress/expected/copy2.out b/src/test/regress/expected/copy2.out index 5f52d6ee6c..5f921dda8a 100644 --- a/src/test/regress/expected/copy2.out +++ b/src/test/regress/expected/copy2.out @@ -195,6 +195,39 @@ COPY y TO stdout WITH CSV FORCE QUOTE *; "Jackson, Sam","\h" "It is ""perfect""."," " "", +-- Repeat above tests with new 8.5 option syntax +COPY y TO stdout (FORMAT CSV); +"Jackson, Sam",\h +"It is ""perfect"".", +"", +COPY y TO stdout (FORMAT CSV, QUOTE '''', DELIMITER '|'); +Jackson, Sam|\h +It is "perfect".| +''| +COPY y TO stdout (FORMAT CSV, FORCE_QUOTE (col2), ESCAPE E'\\'); +"Jackson, Sam","\\h" +"It is \"perfect\"."," " +"", +COPY y TO stdout (FORMAT CSV, FORCE_QUOTE *); +"Jackson, Sam","\h" +"It is ""perfect""."," " +"", +\copy y TO stdout (FORMAT CSV) +"Jackson, Sam",\h +"It is ""perfect"".", +"", +\copy y TO stdout (FORMAT CSV, QUOTE '''', DELIMITER '|') +Jackson, Sam|\h +It is "perfect".| +''| +\copy y TO stdout (FORMAT CSV, FORCE_QUOTE (col2), ESCAPE E'\\') +"Jackson, Sam","\\h" +"It is \"perfect\"."," " +"", +\copy y TO stdout (FORMAT CSV, FORCE_QUOTE *) +"Jackson, Sam","\h" +"It is ""perfect""."," " +"", --test that we read consecutive LFs properly CREATE TEMP TABLE testnl (a int, b text, c int); COPY testnl FROM stdin CSV; |