We're Moving!

The Vertica Forum is moving to a new OpenText Analytics Database (Vertica) Community.

Join us there to post discussion topics, learn about

product releases, share tips, access the blog, and much more.

Create My New Community Account Now


How to copy data via csv file between clusters — Vertica Forum

How to copy data via csv file between clusters

I have some tables in Cluster 1 - I want the data from these tables copying to another cluster for a refresh and sone testing - Its not possible to do this using export so I am trying to use copy .. On the source cluster I am dumping the data to a file as follows (Which seems to give me a CSV / txt file) vsql -U user_name -w user_password -F ',' -At -o exp_USER_PASSWORD_HISTORY.txt -c "select * from USER_PASSWORD_HISTORY;" I copy the text fiile to the other cluster. The user on the other cluster is the same / the table already exists (same structure) and has been truncated. Now I am struggling to get the copy into the destination cluster to work, Please advise?

Comments

  • this works cat /home/dbadmin/xtest/exp_dumps/exp_ACCOUNT_LOGON.txt | vsql -c "COPY schema_owner.ACCOUNT_LOGON FROM STDIN DELIMITER ',' DIRECT";

Leave a Comment

BoldItalicStrikethroughOrdered listUnordered list
Emoji
Image
Align leftAlign centerAlign rightToggle HTML viewToggle full pageToggle lights
Drop image/file