Skip to main content

Most Efficient way to update one column

  • March 22, 2016
  • 1 reply
  • 6 views

knows_not_much
Forum|alt.badge.img+1

Hello,

 

I have a very large table. (120 million rows +). I want to update all the values in a single column.

 

what is the most efficient way of doing this?

 

I was thinking that I will create another table and then issue a update query based on join.

 

Is there a better / faster way? 

1 reply

eli_revach
Forum|alt.badge.img+2
  • Participating Frequently
  • March 22, 2016

Hi
Many factors are missing in your post , like your cluster setup / amount of projections /amount of columns .

For large must delete / update operations "rebuilding Table approch" (in the same time set the new values to the column ) is the one you like to go with , you need to considure the netwrok and disk storage impcats that will take place during the execution of sucg process .

 

https://my.vertica.com/docs/7.1.x/HTML/Content/Authoring/AdministratorsGuide/ManageDiskSpace/RebuildingATable.htm.

 

 

Thanks