COPY FROM STDIN
command imports data directly from the client into a table. It simplifies the copy process by eliminating the need to transfer files to the server.
table_name
: table where the data will be importedstdin
: data coming from the standard input (client application),
.
FROM stdin
to customize the import process.
IMPORT 0
at the end of the line.
psql
client application and creating the film
table, download the film-dataset.csv file and execute the following query:
table_name
with your target table name/path/to/file
with the full path to your CSV fileHEADER
if your CSV file includes column headerscat
Methodpsql
, please follow the following steps:
\q
followed by Enter
to exit psql
COPY
command.