public inbox for [email protected]
help / color / mirror / Atom feed[help] Error in database import
2+ messages / 2 participants
[nested] [flat]
* [help] Error in database import
@ 2024-04-20 03:58 Tu Ho <[email protected]>
2024-04-20 04:27 ` Re: [help] Error in database import Adrian Klaver <[email protected]>
0 siblings, 1 reply; 2+ messages in thread
From: Tu Ho @ 2024-04-20 03:58 UTC (permalink / raw)
To: [email protected]
Hi,
I am currently having a project where I need to combine 2 large database. I
was not however able to import an excel file .csv into the database. The
error was ERROR: syntax error at or near "OIDS" LINE 1: ...ing Site" ,
"International Name(s)" ) FROM STDIN OIDS DELI...
^"
I have no idea how to fix this because I used the "upload file"
option. What should I do?
^ permalink raw reply [nested|flat] 2+ messages in thread
* Re: [help] Error in database import
2024-04-20 03:58 [help] Error in database import Tu Ho <[email protected]>
@ 2024-04-20 04:27 ` Adrian Klaver <[email protected]>
0 siblings, 0 replies; 2+ messages in thread
From: Adrian Klaver @ 2024-04-20 04:27 UTC (permalink / raw)
To: Tu Ho <[email protected]>; [email protected]
On 4/19/24 20:58, Tu Ho wrote:
> Hi,
>
> I am currently having a project where I need to combine 2 large
> database. I was not however able to import an excel file .csv into the
There are Excel files(.xls/.xlsx) and there are *.csv files.
> database. The error was ERROR: syntax error at or near "OIDS" LINE 1:
> ...ing Site" , "International Name(s)" ) FROM STDIN OIDS DELI...
> ^"
>
> I have no idea how to fix this because I used the "upload file"
> option. What should I do?
Use a recent version of whatever client you are using as:
https://www.postgresql.org/docs/current/sql-copy.html
"If 1, OIDs are included in the data; if 0, not. Oid system columns are
not supported in PostgreSQL anymore, but the format still contains the
indicator."
Your client is using old syntax as the last version of Postgres that
allowed FROM STDIN OIDS was:
https://www.postgresql.org/docs/11/sql-copy.html
"where option can be one of:
FORMAT format_name
OIDS [ boolean ]
"
And Postgres 11 is ~6 months past EOL.
--
Adrian Klaver
[email protected]
^ permalink raw reply [nested|flat] 2+ messages in thread
end of thread, other threads:[~2024-04-20 04:27 UTC | newest]
Thread overview: 2+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2024-04-20 03:58 [help] Error in database import Tu Ho <[email protected]>
2024-04-20 04:27 ` 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