public inbox for [email protected]help / color / mirror / Atom feed
end of COPY 5+ messages / 4 participants [nested] [flat]
* end of COPY @ 2025-03-05 15:22 Marc Millas <[email protected]> 0 siblings, 3 replies; 5+ messages in thread From: Marc Millas @ 2025-03-05 15:22 UTC (permalink / raw) To: [email protected] <[email protected]> Hi, on a Postgres 16 DB running on a redhat 8.5 x86 machineI want to input some data using copy from stdin so.. more that 700 000 lines goes well. Then the flow contains a single line: \. to my understanding this means end of the copy but, Postgres generates an error : invalid input syntax for type numeric "\." then the 2 lines stating the copy command that was executed. what am I missing ? thanks Marc MILLAS Senior Architect +33607850334 www.mokadb.com ^ permalink raw reply [nested|flat] 5+ messages in thread
* Re: end of COPY @ 2025-03-05 15:40 Ron Johnson <[email protected]> parent: Marc Millas <[email protected]> 2 siblings, 0 replies; 5+ messages in thread From: Ron Johnson @ 2025-03-05 15:40 UTC (permalink / raw) To: [email protected] <[email protected]> On Wed, Mar 5, 2025 at 10:22 AM Marc Millas <[email protected]> wrote: > Hi, > on a Postgres 16 DB running on a redhat 8.5 x86 machineI want to input > some data using copy from stdin > so.. more that 700 000 lines goes well. > Then the flow contains a single line: \. > to my understanding this means end of the copy > I just tested this on PG 16.8. No backslash. $ psql TAP -Xc "copy public.job_notification TO STDOUT;" https://www.postgresql.org/docs/16/sql-copy.html "End of data *can be* represented by a single line containing just backslash-period (\.)." "the end-of-data marker (\.) or the null string (\N by default)." > but, Postgres generates an error : > invalid input syntax for type numeric "\." > then the 2 lines stating the copy command that was executed. > > what am I missing ? > COPY is expecting something after the backslash. -- Death to <Redacted>, and butter sauce. Don't boil me, I'm still alive. <Redacted> lobster! ^ permalink raw reply [nested|flat] 5+ messages in thread
* Re: end of COPY @ 2025-03-05 15:52 Greg Sabino Mullane <[email protected]> parent: Marc Millas <[email protected]> 2 siblings, 1 reply; 5+ messages in thread From: Greg Sabino Mullane @ 2025-03-05 15:52 UTC (permalink / raw) To: Marc Millas <[email protected]>; +Cc: [email protected] <[email protected]>; Ron Johnson <[email protected]> On Wed, Mar 5, 2025 at 10:22 AM Marc Millas <[email protected]> wrote: > Then the flow contains a single line: \. to my understanding this means > end of the copy > > but, Postgres generates an error : invalid input syntax for type numeric > "\." > This can happen when you send TWO backslashes and a dot, rather than a single backslash and a dot. Cheers, Greg -- Crunchy Data - https://www.crunchydata.com Enterprise Postgres Software Products & Tech Support ^ permalink raw reply [nested|flat] 5+ messages in thread
* Re: end of COPY @ 2025-03-05 15:55 Adrian Klaver <[email protected]> parent: Marc Millas <[email protected]> 2 siblings, 0 replies; 5+ messages in thread From: Adrian Klaver @ 2025-03-05 15:55 UTC (permalink / raw) To: Marc Millas <[email protected]>; [email protected] <[email protected]> On 3/5/25 07:22, Marc Millas wrote: > Hi, > on a Postgres 16 DB running on a redhat 8.5 x86 machineI want to input > some data using copy from stdin > so.. more that 700 000 lines goes well. > Then the flow contains a single line: \. > to my understanding this means end of the copy Provide the lines at the end of the data. > > but, Postgres generates an error : > invalid input syntax for type numeric "\." > then the 2 lines stating the copy command that was executed. Provide the complete error message. > > what am I missing ? > > thanks > > > Marc MILLAS > Senior Architect > +33607850334 > www.mokadb.com <http://www.mokadb.com; > -- Adrian Klaver [email protected] ^ permalink raw reply [nested|flat] 5+ messages in thread
* Re: end of COPY @ 2025-03-05 15:59 Ron Johnson <[email protected]> parent: Greg Sabino Mullane <[email protected]> 0 siblings, 0 replies; 5+ messages in thread From: Ron Johnson @ 2025-03-05 15:59 UTC (permalink / raw) To: pgsql-general On Wed, Mar 5, 2025 at 10:53 AM Greg Sabino Mullane <[email protected]> wrote: > On Wed, Mar 5, 2025 at 10:22 AM Marc Millas <[email protected]> > wrote: > >> Then the flow contains a single line: \. to my understanding this means >> end of the copy >> >> but, Postgres generates an error : invalid input syntax for type numeric >> "\." >> > > This can happen when you send TWO backslashes and a dot, rather than a > single backslash and a dot. > I hate proportional fonts. 😠 -- Death to <Redacted>, and butter sauce. Don't boil me, I'm still alive. <Redacted> lobster! ^ permalink raw reply [nested|flat] 5+ messages in thread
end of thread, other threads:[~2025-03-05 15:59 UTC | newest] Thread overview: 5+ messages (download: mbox mbox.gz follow: Atom feed) -- links below jump to the message on this page -- 2025-03-05 15:22 end of COPY Marc Millas <[email protected]> 2025-03-05 15:40 ` Ron Johnson <[email protected]> 2025-03-05 15:52 ` Greg Sabino Mullane <[email protected]> 2025-03-05 15:59 ` Ron Johnson <[email protected]> 2025-03-05 15:55 ` Adrian Klaver <[email protected]>
This inbox is served by agora; see mirroring instructions for how to clone and mirror all data and code used for this inbox