copy command

Moderator: NorbertKrupa

Post Reply
vignesh_man
Newbie
Newbie
Posts: 3
Joined: Tue Jul 24, 2012 1:39 pm

copy command

Post by vignesh_man » Tue Jul 24, 2012 2:12 pm

Can we enforce commit intervals using copy command in vertica database?

User avatar
JimKnicely
Site Admin
Site Admin
Posts: 1825
Joined: Sat Jan 21, 2012 4:58 am
Contact:

Re: copy command

Post by JimKnicely » Tue Jul 24, 2012 8:24 pm

Hi vignesh_man,

Welcome to vertica-forums.com!

Unfortunately (as of Vertica 6.0.0-3) there is not an option of the COPY command that will commit portions of the records copied... There is one commit at the end. Keep in mind, this is probably a good idea because you want the data to load ASAP and I've found having a lot of transactions is bad for performance.

Note: The autocommit variable can only be turned on or off... I was hoping, like in Oracle, we could set the variable equal to a commit interval:

Code: Select all

dbadmin=> set autocommit = 100;
ERROR 5415:  Value must be either ON or OFF
Is there any way you can break up the data you want to load into multiple files where each file contains the set number of records that you want the commit interval to be?

Thanks.
Jim Knicely

Image

Note: I work for Vertica. My views, opinions, and thoughts expressed here do not represent those of my employer.

jfur2133
Newbie
Newbie
Posts: 1
Joined: Fri Aug 31, 2012 3:55 pm

Re: copy command

Post by jfur2133 » Fri Aug 31, 2012 3:58 pm

Are there any plans to add a COMMIT to the COPY command? The problem we are running into is when we load a large table we run out of temp space.

User avatar
JimKnicely
Site Admin
Site Admin
Posts: 1825
Joined: Sat Jan 21, 2012 4:58 am
Contact:

Re: copy command

Post by JimKnicely » Fri Aug 31, 2012 4:09 pm

Please check out this post:

viewtopic.php?f=60&t=314&p=1280#p1280

The forums' user jpcavanaugh has generously offered to send "New Feature" requests to Vertica for us!
Jim Knicely

Image

Note: I work for Vertica. My views, opinions, and thoughts expressed here do not represent those of my employer.

Post Reply

Return to “New to Vertica”