The UNIX and Linux Forums  
Hello and Welcome from United States to the UNIX and Linux Forums! Thank You for Visiting and Joining Our Global Community.

Go Back   The UNIX and Linux Forums > Top Forums > UNIX for Advanced & Expert Users
.
google unix.com




View Single Post in the UNIX and Linux Forums - Click on the Thread or Permalink to View Entire Thread -->
  #1 (permalink)  
Old 08-02-2005
matrixmadhan matrixmadhan is offline Forum Advisor  
Technorati Master
  
 

Join Date: Mar 2005
Location: leaf node in B+ tree
Posts: 2,954
multiple updates

Hi all,

I would like to perform multiple updates within a single database open and close.

Box: solaris
dB: informix

This is how i do perform for single update

dbaccess <dbname> -<<EOF
update table1 set col1=1 where col2=1
EOF

i have the col1 values in a file (some 1000 values)
now how do i proceed with an update of 100 values at a time and give a commit. The above sample is time consuming as it has to open and close the database for each and every update done.


And between the dbaccess and EOF i cannot read from the file as within them only database operations are allowed and no file manipulation, storing in variables are allowed.

Any help would be greatly appreciated.

Thanks.