sql batch upadates

This is a discussion on "sql batch upadates" within the Databases section. This forum, and the thread "sql batch upadates are both part of the Program Your Website category.


 Subscribe in a reader

Go Back   Webforumz.com > Main Forums > Program Your Website > Databases

Notices




Reply
 
LinkBack Thread Tools
  #1  
Old Nov 5th, 2005, 11:17
Junior Member
Join Date: May 2005
Location: bath - england
Posts: 39
Thanks: 0
Thanked 0 Times in 0 Posts
sql batch upadates

Hi,
I'm sure there is a method for executing a whole bunch of sql commands in one go to save connection resources, but I can't find details anywhere.

eg. I have code which loops through an array of criteria updating the relevant database record each time. It would be good to save all of the updates to the end so as to avoid so many executions. My current code is:

ids=(1,2,3,4,5,6,7,8,9,10,11,12,13,14) 'to include hundreds of values

for i = 0 to Ubound(ids)
sql= "UPDATE mytable SET mycolumn='value' WHERE id='"&ids(i)&"'"
objconn.execute(sql)
next

Thanks
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote

Reply

Tags
sql, batch, upadates

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Similar Threads
Thread Thread Starter Forum Replies Last Post
Batch Watermark Images thebeatsuite Graphics and 3D 12 Aug 8th, 2007 09:33
Changing Keywords on a batch of pages grandadbob Search Engine Optimization (SEO) 1 Jul 2nd, 2007 15:57
designing a site for batch image upload/download & viewing zephicus Starting Out 1 Mar 22nd, 2007 10:27
Dreamweaver Templates - applying to batch pages wheatus Web Page Design 0 Apr 15th, 2004 12:18


All times are GMT. The time now is 21:00.


Powered by vBulletin®
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.2.0 RC8
© 2003-2008 Webforumz.com : All Rights Reserved